/* KraftedLogic Games Center — hub layout (scoped .gc- prefix) */
/* Uses KraftedLogic brand colors: navy (#233746) and teal (#12B6A6) */

:root {
  --gc-bg: #1a2530;
  --gc-surface: #233746;
  --gc-border: #3a4d5c;
  --gc-text: #f8fafc;
  --gc-muted: #94a3b8;
  --gc-accent: #12B6A6;
  --gc-accent-hover: #16d4c2;
  --gc-success: #34d399;
  --gc-warning: #fbbf24;
  --gc-radius: 12px;
  --gc-max: 56rem;
}

.gc-page {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(165deg, var(--gc-bg) 0%, #152028 45%, var(--gc-bg) 100%);
  color: var(--gc-text);
  font-family: 'Inter', system-ui, sans-serif;
  line-height: 1.5;
}

.gc-header {
  border-bottom: 1px solid var(--gc-border);
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.gc-header__inner {
  max-width: var(--gc-max);
  margin: 0 auto;
  padding: var(--space-md, 1rem) var(--space-md, 1rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.gc-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--gc-text);
  font-weight: 600;
}

.gc-brand a {
  color: inherit;
  text-decoration: none;
}

.gc-brand img {
  width: 36px;
  height: 36px;
}

.gc-brand span {
  font-size: 1.05rem;
}

.gc-nav a {
  color: var(--gc-muted);
  text-decoration: none;
  font-size: 0.9rem;
}

.gc-nav a:hover {
  color: var(--gc-accent);
}

.gc-header__right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.gc-header-signin {
  padding: 0.4rem 0.9rem;
  font-size: 0.85rem;
}

.gc-header-user {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.85rem;
  color: var(--gc-muted);
}

.gc-main {
  max-width: var(--gc-max);
  margin: 0 auto;
  padding: 2rem var(--space-md, 1rem) 3rem;
}

.gc-hero__eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0.03em;
  color: var(--gc-accent);
  margin: 0 0 0.5rem;
}

.gc-hero h1 {
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 700;
  margin: 0 0 0.75rem;
  line-height: 1.2;
}

.gc-hero__lead {
  color: var(--gc-muted);
  font-size: 1.05rem;
  max-width: 40rem;
  margin: 0 0 1.5rem;
}

.gc-section {
  margin-top: 2.5rem;
}

.gc-section__title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.25rem;
}

.gc-section__desc {
  color: var(--gc-muted);
  font-size: 0.9rem;
  margin: 0 0 1rem;
}

/* User session placeholder */
.gc-session {
  background: var(--gc-surface);
  border: 1px solid var(--gc-border);
  border-radius: var(--gc-radius);
  padding: 1.25rem 1.5rem;
}

.gc-session__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.gc-session__label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gc-warning);
  margin: 0 0 0.25rem;
}

.gc-session h2 {
  font-size: 1.15rem;
  margin: 0;
}

.gc-session-hint {
  font-size: 0.85rem;
  color: var(--gc-muted);
}

/* App grid */
.gc-apps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.gc-app-card {
  position: relative;
  background: var(--gc-surface);
  border: 1px solid var(--gc-border);
  border-radius: var(--gc-radius);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.gc-app-card:hover {
  border-color: rgba(167, 139, 250, 0.4);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.gc-app-card[data-recent='true'] {
  border-color: rgba(52, 211, 153, 0.4);
}

.gc-app-card__icon {
  font-size: 2.5rem;
  line-height: 1;
  margin-bottom: 0.75rem;
}

/* Card-back style icon with KraftedLogic logo */
.gc-card-icon {
  width: 48px;
  height: 64px;
  background: linear-gradient(145deg, #e8eaed 0%, #c9cdd1 100%);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 
    0 2px 8px rgba(0,0,0,0.2),
    inset 0 1px 0 rgba(255,255,255,0.5);
  position: relative;
  border: 1px solid rgba(100, 116, 139, 0.3);
}

.gc-card-icon::before {
  content: '';
  position: absolute;
  inset: 4px;
  border: 1px solid rgba(100, 116, 139, 0.25);
  border-radius: 3px;
}

.gc-card-icon img {
  width: 28px;
  height: 28px;
  opacity: 0.85;
}

.gc-app-card__badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
}

.gc-app-card__badge--live {
  background: rgba(52, 211, 153, 0.2);
  color: var(--gc-success);
}

.gc-app-card__badge--beta {
  background: rgba(167, 139, 250, 0.2);
  color: var(--gc-accent);
}

.gc-app-card__badge--soon {
  background: rgba(148, 163, 184, 0.15);
  color: var(--gc-muted);
}

.gc-app-card__title {
  font-size: 1.2rem;
  margin: 0 0 0.25rem;
  padding-right: 4.5rem;
}

.gc-app-card__players {
  font-size: 0.8rem;
  color: var(--gc-accent);
  margin-bottom: 0.35rem;
}

.gc-app-card__tagline {
  font-size: 0.875rem;
  color: var(--gc-muted);
  margin: 0 0 1rem;
  flex: 1;
}

.gc-app-card__cta {
  align-self: flex-start;
  text-decoration: none;
  display: inline-block;
  text-align: center;
}

.btn {
  border: none;
  border-radius: 8px;
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}

.btn-primary {
  background: var(--gc-accent);
  color: #0f172a;
}

.btn-primary:hover {
  background: var(--gc-accent-hover);
}

.btn-ghost {
  background: transparent;
  color: var(--gc-muted);
  border: 1px solid var(--gc-border);
  cursor: default;
}

/* Outline button */
.gc-btn-outline {
  display: inline-block;
  padding: 0.4rem 0.85rem;
  border: 1px solid var(--gc-border);
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gc-text);
  text-decoration: none;
  background: transparent;
  cursor: pointer;
  font-family: inherit;
  transition: border-color 0.15s, color 0.15s;
}
.gc-btn-outline:hover  { border-color: var(--gc-accent); color: var(--gc-accent); }
.gc-btn-outline--sm    { padding: 0.25rem 0.6rem; font-size: 0.78rem; }

/* Session view — user header */
.gc-session-user {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.gc-session-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(167, 139, 250, 0.12);
  border: 2px solid rgba(167, 139, 250, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.gc-session-avatar__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.gc-session-avatar__initials {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--gc-accent);
}

.gc-session-games {
  margin-top: 1rem;
}

.gc-footer {
  max-width: var(--gc-max);
  margin: 3rem auto 0;
  padding: 1.5rem var(--space-md, 1rem);
  border-top: 1px solid var(--gc-border);
  color: var(--gc-muted);
  font-size: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
}

.gc-footer a {
  color: var(--gc-accent);
  text-decoration: none;
}

.gc-footer a:hover {
  text-decoration: underline;
}

/* ── Login Modal ─────────────────────────────────────────────────────────── */
.gc-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 1rem;
}

.gc-modal {
  background: var(--gc-surface);
  border-radius: var(--gc-radius);
  width: 100%;
  max-width: 380px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  overflow: hidden;
}

.gc-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--gc-border);
}

.gc-modal-title {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
}

.gc-modal-close {
  background: none;
  border: none;
  color: var(--gc-muted);
  font-size: 1.5rem;
  cursor: pointer;
  line-height: 1;
  padding: 0;
}

.gc-modal-close:hover {
  color: var(--gc-text);
}

.gc-modal-body {
  padding: 1.25rem;
  overflow: hidden;
}

.gc-form-group {
  margin-bottom: 1rem;
}

.gc-form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 0.35rem;
  color: var(--gc-muted);
}

.gc-form-input {
  width: 100%;
  box-sizing: border-box;
  padding: 0.6rem 0.75rem;
  background: var(--gc-bg);
  border: 1px solid var(--gc-border);
  border-radius: 8px;
  color: var(--gc-text);
  font-size: 0.95rem;
  font-family: inherit;
}

.gc-form-input:focus {
  outline: none;
  border-color: var(--gc-accent);
}

.gc-form-error {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-size: 0.85rem;
  margin-bottom: 1rem;
}

.gc-btn-block {
  width: 100%;
  box-sizing: border-box;
  padding: 0.65rem 1rem;
}

.gc-divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 1.25rem 0;
  color: var(--gc-muted);
  font-size: 0.85rem;
}

.gc-divider::before,
.gc-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gc-border);
}

.gc-btn-google {
  width: 100%;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.6rem 1rem;
  background: #fff;
  color: #333;
  border: none;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s;
}

.gc-btn-google:hover {
  background: #f1f1f1;
}

.gc-btn-google img {
  width: 20px;
  height: 20px;
}

.gc-modal-hint {
  margin: 1.25rem 0 0;
  font-size: 0.82rem;
  color: var(--gc-muted);
  text-align: center;
}

.gc-modal-hint a {
  color: var(--gc-accent);
  text-decoration: none;
}

.gc-modal-hint a:hover {
  text-decoration: underline;
}
