/* DigitalRateCard — Owner Admin Styles */

.owner-layout {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

/* ── Top bar ── */
/* Sticky wrapper holds topbar + dropdown nav together */
.owner-header {
  position: sticky;
  top: 0;
  z-index: 200;
}

.owner-topbar {
  background: var(--color-primary);
  color: #fff;
  padding: .75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.owner-topbar-brand    { display: flex; align-items: center; text-decoration: none; line-height: 1; }
.owner-topbar-meta     { font-size: .82rem; opacity: .85; }
.owner-topbar-right    { display: flex; align-items: center; gap: .75rem; }
.owner-topbar-signout  { background: rgba(255,255,255,.15); color: #fff; border: 1px solid rgba(255,255,255,.3); }

/* ── Hamburger button (mobile only) ── */
.owner-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  flex-shrink: 0;
}
.owner-hamburger span {
  display: block;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform .25s, opacity .25s;
}
.owner-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.owner-hamburger.open span:nth-child(2) { opacity: 0; }
.owner-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Nav — desktop: horizontal tab bar ── */
.owner-nav {
  display: flex;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.owner-nav::-webkit-scrollbar { display: none; }

.owner-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .15rem;
  padding: .65rem .9rem;
  text-decoration: none;
  color: var(--color-muted);
  font-size: .78rem;
  font-weight: 600;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  transition: color .15s, border-color .15s;
}
.owner-nav-item:hover  { color: var(--color-primary); text-decoration: none; }
.owner-nav-item.active { color: var(--color-primary); border-bottom-color: var(--color-primary); }
.owner-nav-icon        { font-size: 1.1rem; }

/* ── Mobile: dropdown from hamburger ── */
@media (max-width: 639px) {
  .owner-hamburger  { display: flex; }
  .owner-topbar-biz { display: none; }

  .owner-nav {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-surface);
    border-bottom: 2px solid var(--color-border);
    box-shadow: 0 8px 24px rgba(0,0,0,.13);
  }
  .owner-nav.owner-nav-open { display: flex; }

  .owner-nav-item {
    flex-direction: row;
    justify-content: flex-start;
    gap: .75rem;
    padding: .85rem 1.25rem;
    font-size: .92rem;
    border-bottom: 1px solid var(--color-border);
    border-left: 4px solid transparent;
    border-bottom-width: 0;
  }
  .owner-nav-item + .owner-nav-item { border-top: 1px solid var(--color-border); }
  .owner-nav-item.active {
    border-left-color: var(--color-primary);
    background: #FFF8F5;
    color: var(--color-primary);
  }
  .owner-nav-icon { font-size: 1.25rem; }
}

/* ── Page content ── */
.owner-content { flex: 1; padding: 1.25rem 1rem 3rem; max-width: 900px; margin: 0 auto; width: 100%; }

/* ── Dashboard stat cards ── */
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
@media(min-width:640px){ .stat-grid { grid-template-columns: repeat(4, 1fr); } }
.stat-card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius); padding: 1.1rem; text-align: center; box-shadow: var(--shadow-sm); }
.stat-value { font-size: 1.75rem; font-weight: 900; color: var(--color-primary); }
.stat-label { font-size: .78rem; color: var(--color-muted); font-weight: 600; margin-top: .2rem; }

/* ── Store URL box ── */
.store-url-box {
  background: #eff6ff;
  border: 1.5px solid #bfdbfe;
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  display: flex;
  align-items: center;
  gap: .75rem;
  flex-wrap: wrap;
}
.store-url-box code { flex: 1; font-size: .88rem; word-break: break-all; color: var(--color-primary); }
.store-url-box .btn { flex-shrink: 0; }

/* ── Catalog table / list ── */
.item-list { display: flex; flex-direction: column; gap: .65rem; }
.item-row {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: .85rem 1rem;
  display: flex;
  align-items: flex-start;
  gap: .75rem;
}
.item-row-thumb {
  width: 56px; height: 56px;
  border-radius: 8px;
  object-fit: cover;
  background: var(--color-bg);
  flex-shrink: 0;
}
.item-row-thumb-placeholder {
  width: 56px; height: 56px;
  border-radius: 8px;
  background: var(--color-bg);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}
.item-row-body { flex: 1; min-width: 0; }
.item-row-name { font-weight: 700; font-size: .95rem; }
.item-row-meta { font-size: .8rem; color: var(--color-muted); margin-top: .15rem; }
.item-row-actions { display: flex; gap: .4rem; flex-wrap: wrap; margin-top: .5rem; }
.item-row-right { display: flex; flex-direction: column; align-items: flex-end; gap: .35rem; flex-shrink: 0; }

/* ── Auth pages ── */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem 1rem;
  background: var(--color-bg);
}
.auth-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 2rem 1.5rem;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-md);
}
.auth-logo { text-align: center; margin-bottom: 1.5rem; }
.auth-logo-text { font-size: 1.4rem; font-weight: 900; color: var(--color-primary); }
.auth-title { font-size: 1.2rem; font-weight: 800; margin-bottom: .25rem; }
.auth-subtitle { font-size: .875rem; color: var(--color-muted); margin-bottom: 1.5rem; }

/* ── Page title row ── */
.page-title-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.25rem; flex-wrap: wrap; gap: .5rem; }
.page-title { font-size: 1.2rem; font-weight: 800; }
