/*
Theme Name: WOT Companion Theme
Theme URI: https://whatontap.com
Author: WOT Team
Author URI: https://whatontap.com
Description: Untappd-inspired UI theme for Beer Tap Manager Pro.
Version: 1.2.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 7.4
Text Domain: wot-theme
*/

:root {
  --bg: #060b16;
  --bg-soft: #0a1426;
  --panel: #101b2f;
  --panel-raised: #16243d;
  --text: #ecf2ff;
  --muted: #95a7c9;
  --brand: #ffb12f;
  --brand-hover: #ff9f0a;
  --success: #28c58b;
  --danger: #ff5d73;
  --border: #223450;
  --border-strong: #32486e;
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --space-1: 0.4rem;
  --space-2: 0.7rem;
  --space-3: 1rem;
  --space-4: 1.4rem;
  --shadow-soft: 0 12px 28px rgba(2, 8, 20, 0.35);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top right, rgba(38, 66, 110, 0.25), transparent 52%),
    radial-gradient(circle at top left, rgba(255, 177, 47, 0.08), transparent 40%),
    var(--bg);
}

a { color: var(--brand); text-decoration: none; transition: .2s ease; }
a:hover { color: #ffd17a; }

.site-header,
.site-footer {
  background: rgba(8, 16, 31, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.site-footer {
  border-top: 1px solid var(--border);
  border-bottom: 0;
  margin-top: 3rem;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--space-4) var(--space-3);
}

.site-main {
  min-height: calc(100vh - 200px);
}

.site-title { margin: 0; font-size: 1.45rem; font-weight: 800; letter-spacing: .01em; }
.site-title a { color: var(--brand); }
.site-tagline { margin: 0.25rem 0 0; color: var(--muted); font-size: .92rem; }

.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.user-chip {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: .45rem .85rem;
  color: var(--muted);
  font-size: .84rem;
  background: rgba(14, 26, 45, 0.75);
}

.main-nav { margin-top: .9rem; }
.main-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: .55rem;
}
.main-nav a {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .55rem .9rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text);
  background: rgba(13, 24, 42, 0.8);
}
.main-nav a:hover { border-color: var(--brand); color: var(--brand); transform: translateY(-1px); }

.quick-nav a { font-size: .9rem; }

.card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(22, 36, 61, 0.88), rgba(16, 27, 47, 0.92));
  box-shadow: var(--shadow-soft);
  padding: var(--space-4);
}

.grid { display: grid; gap: var(--space-3); }
.grid-2 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
@media (min-width: 860px) {
  .grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  min-height: 40px;
  padding: .58rem 1rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: linear-gradient(180deg, #ffc24f, var(--brand));
  color: #1d1200;
  font-weight: 700;
  cursor: pointer;
}
.btn:hover { background: linear-gradient(180deg, #ffc95f, var(--brand-hover)); color: #120a00; }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn.btn-dark {
  background: rgba(12, 24, 43, 0.9);
  border-color: var(--border-strong);
  color: var(--text);
}
.btn.btn-dark:hover { background: rgba(20, 33, 56, 0.95); color: #fff; }
.btn.btn-ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text);
}

.entry-title { margin: 0 0 .4rem; font-size: 1.55rem; line-height: 1.25; }
.section-title { margin: 0 0 .4rem; font-size: 1.12rem; }
.section-note, .muted { color: var(--muted); }

.input-dark,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
select,
textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: rgba(7, 14, 28, 0.88);
  color: var(--text);
  padding: .62rem .75rem;
  outline: none;
}
input:focus, select:focus, textarea:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(255, 177, 47, 0.2);
}

.list-reset { list-style: none; margin: 0; padding: 0; }
.stack-sm > * + * { margin-top: .55rem; }
.stack-md > * + * { margin-top: 1rem; }

.premium-hero {
  background:
    radial-gradient(circle at top right, rgba(255, 177, 47, 0.2), transparent 45%),
    linear-gradient(145deg, rgba(18, 31, 53, 0.95), rgba(13, 24, 43, 0.95));
  border-color: rgba(255, 177, 47, 0.35);
}
.premium-hero-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  flex-wrap: wrap;
}
.hero-actions { display: flex; gap: .55rem; flex-wrap: wrap; }

.metric-strip {
  margin-top: var(--space-3);
  display: grid;
  gap: .8rem;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}
.metric-card {
  border: 1px solid rgba(255, 177, 47, 0.35);
  border-radius: var(--radius-sm);
  padding: .75rem .85rem;
  background: rgba(10, 20, 37, 0.85);
}
.metric-card.is-warning { border-color: rgba(255, 93, 115, 0.65); }
.metric-label { display: block; color: var(--muted); font-size: .8rem; }
.metric-value { font-size: 1.35rem; font-weight: 700; }

.catalog-section { margin: 1.3rem 0 1.8rem; }
.section-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: .75rem;
  flex-wrap: wrap;
  margin-bottom: .8rem;
}
.toolbar-actions { display: flex; gap: .6rem; flex-wrap: wrap; }

.catalog-list { display: grid; gap: .85rem; }
.catalog-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(12, 24, 43, 0.9);
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: .9rem;
  flex-wrap: wrap;
}
.catalog-main { min-width: 260px; }
.catalog-title { margin: 0 0 .28rem; font-size: 1.02rem; font-weight: 700; }
.catalog-sub { margin: 0; color: var(--muted); font-size: .92rem; }
.catalog-status {
  display: inline-block;
  margin-top: .45rem;
  padding: .25rem .55rem;
  border-radius: 999px;
  font-size: .79rem;
  background: rgba(255, 177, 47, .15);
  color: #ffd17a;
}
.catalog-status.is-active { background: rgba(40, 197, 139, .18); color: #77f7c4; }
.catalog-status.is-muted { background: rgba(116, 143, 186, .18); color: #cad8f2; }
.catalog-actions { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }

.pill {
  display: inline-block;
  border: 1px solid rgba(255, 177, 47, .35);
  border-radius: 999px;
  padding: .18rem .52rem;
  margin-right: .35rem;
  font-size: .78rem;
  color: #ffe8b8;
  background: rgba(255, 177, 47, 0.1);
}

.premium-grid .card { transition: transform .18s ease, box-shadow .18s ease; }
.premium-grid .card:hover { transform: translateY(-4px); }

.table-shell {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
table { width: 100%; border-collapse: collapse; }
th, td { padding: .6rem .7rem; border-bottom: 1px solid rgba(50, 72, 110, 0.45); text-align: left; }
th { color: var(--muted); font-size: .8rem; text-transform: uppercase; letter-spacing: .03em; }

.empty-state {
  text-align: center;
  padding: 2rem 1.2rem;
  color: var(--muted);
}

@media (max-width: 740px) {
  .container { padding: 1rem .75rem; }
  .card { padding: 1rem; }
  .entry-title { font-size: 1.35rem; }
}

/* Page-specific polish */
.register-page .premium-hero {
  max-width: 860px;
  margin: 0 auto;
}
.register-error {
  border: 1px solid rgba(255, 93, 115, 0.55);
  background: rgba(255, 93, 115, 0.12);
  color: #ffd8de;
}
.register-choices .card {
  min-height: 180px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.ops-toolbar { margin-top: 10px; }
.ops-toolbar .input-dark { max-width: 420px; }
.ops-toolbar .input-dark.ops-filter { max-width: 220px; }
.ops-layout {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: var(--space-3);
  align-items: start;
}
@media (max-width: 980px) {
  .ops-layout { grid-template-columns: 1fr; }
}
.ops-toast-root {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 9999;
}
.ops-toast {
  padding: 10px 12px;
  margin-top: 8px;
  border-radius: var(--radius-sm);
}
.receipt-row-remove {
  min-height: 28px;
  padding: .2rem .55rem;
}

.catalog-actions a.btn {
  min-width: 92px;
}
