@import url("https://fonts.googleapis.com/css2?family=Fraunces:wght@600;700&family=Space+Grotesk:wght@400;500;600;700&display=swap");

/* =========================
   Global.css — HöganäsEvents (New Theme)
   - Ljus + mörk tema med ny palett
   - Samma header/nav/hamburger-struktur
========================= */

:root{
  /* Base */
  --bg0: #F7F4EF;
  --bg1: #EDF2F2;

  --card: rgba(255,255,255,0.90);
  --card2: rgba(255,255,255,0.82);
  --stroke: rgba(30,24,16,0.10);

  --text-strong: rgba(22,18,14,0.95);
  --text: rgba(22,18,14,0.88);
  --text-muted: rgba(22,18,14,0.62);
  --text-muted-2: rgba(22,18,14,0.52);
  --text-soft: rgba(22,18,14,0.72);
  --text-icon: rgba(22,18,14,0.80);

  --muted: rgba(22,18,14,0.64);
  --muted2: rgba(22,18,14,0.48);

  --page-bg: #F3EFE7;
  --surface: rgba(255,255,255,0.80);
  --surface-strong: rgba(255,255,255,0.92);
  --surface-stronger: rgba(255,255,255,0.97);
  --surface-muted: rgba(30,24,16,0.06);
  --surface-muted-2: rgba(30,24,16,0.04);
  --surface-muted-3: rgba(30,24,16,0.10);

  --border: rgba(30,24,16,0.12);
  --border-soft: rgba(30,24,16,0.08);
  --border-soft-2: rgba(30,24,16,0.06);
  --border-strong: rgba(30,24,16,0.16);

  --nav-bg: rgba(255,255,255,0.86);
  --nav-border: rgba(30,24,16,0.12);
  --nav-item-hover-bg: rgba(255,255,255,0.96);
  --nav-item-hover-border: var(--border-strong);  /* Accent */
  --accent: #0F766E;
  --accent-strong: #0B5F58;
  --accent-rgb: 15,118,110;
  --accent-soft: rgba(var(--accent-rgb),0.12);
  --accent-soft-2: rgba(var(--accent-rgb),0.18);
  --accent-soft-3: rgba(var(--accent-rgb),0.24);
  --accent-border: rgba(var(--accent-rgb),0.28);
  --accent-border-2: rgba(var(--accent-rgb),0.18);
  --accent-border-3: rgba(var(--accent-rgb),0.35);
  --accent-ring: rgba(var(--accent-rgb),0.32);
  --accent-shadow: rgba(var(--accent-rgb),0.22);
  --accent-shadow-strong: rgba(var(--accent-rgb),0.30);
  --accent-strong-soft: rgba(var(--accent-rgb),0.55);

  --accent2: #22C55E;
  --warm: #F59E0B;
  --badge-verified: var(--accent);
  --badge-verified-border: var(--accent-border);
  --badge-admin: #F59E0B;
  --badge-admin-border: rgba(245,158,11,0.45);

  --danger: #DC2626;
  --danger-rgb: 220,38,38;
  --danger-soft: rgba(var(--danger-rgb),0.12);
  --danger-border: rgba(var(--danger-rgb),0.28);
  --danger-border-strong: rgba(var(--danger-rgb),0.38);

  --success: #16A34A;
  --success-rgb: 22,163,74;
  --success-soft: rgba(var(--success-rgb),0.12);
  /* Layout */
  --header-h: 66px;
  --radius: 18px;

  /* Shadow */
  --shadow-lg: 0 26px 70px rgba(20,16,12,0.14);
  --shadow-md: 0 16px 44px rgba(20,16,12,0.12);
  --shadow-sm: 0 10px 26px rgba(20,16,12,0.10);

  /* Motion */
  --ease-out: cubic-bezier(.16,1,.3,1);
  --ease-pop: cubic-bezier(.2,1.2,.3,1);
  --dur-1: 140ms;
  --dur-2: 220ms;
  --dur-3: 520ms;

  font-family: "Space Grotesk", "Manrope", "Segoe UI", sans-serif;
  line-height: 1.5;
  font-weight: 400;
  color: var(--text);
  background:
    radial-gradient(900px 650px at 18% 12%, rgba(15,118,110,0.10), transparent 60%),
    radial-gradient(820px 600px at 88% 18%, rgba(245,158,11,0.10), transparent 60%),
    radial-gradient(900px 700px at 40% 92%, rgba(17,94,89,0.08), transparent 60%),
    linear-gradient(180deg, var(--bg0), var(--bg1));
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

:root[data-theme="dark"]{
  color-scheme: dark;

  --bg0: #0B0F14;
  --bg1: #0E1620;

  --card: rgba(14,20,28,0.90);
  --card2: rgba(14,20,28,0.70);
  --stroke: rgba(148,163,184,0.22);

  --text-strong: rgba(248,250,252,0.96);
  --text: rgba(226,232,240,0.92);
  --text-muted: rgba(148,163,184,0.78);
  --text-muted-2: rgba(148,163,184,0.62);
  --text-soft: rgba(203,213,225,0.82);
  --text-icon: rgba(226,232,240,0.88);

  --muted: rgba(148,163,184,0.75);
  --muted2: rgba(148,163,184,0.60);

  --page-bg: #0B0F14;
  --surface: rgba(14,20,28,0.78);
  --surface-strong: rgba(18,26,36,0.90);
  --surface-stronger: rgba(18,26,36,0.96);
  --surface-muted: rgba(148,163,184,0.12);
  --surface-muted-2: rgba(148,163,184,0.08);
  --surface-muted-3: rgba(148,163,184,0.18);

  --border: rgba(148,163,184,0.28);
  --border-soft: rgba(148,163,184,0.20);
  --border-soft-2: rgba(148,163,184,0.14);
  --border-strong: rgba(148,163,184,0.32);

  --nav-bg: rgba(12,18,26,0.88);
  --nav-border: rgba(148,163,184,0.22);
  --nav-item-hover-bg: rgba(30,41,59,0.92);
  --nav-item-hover-border: rgba(148,163,184,0.38);
  --accent: #2DD4BF;
  --accent-strong: #14B8A6;
  --accent-rgb: 45,212,191;
  --accent-soft: rgba(var(--accent-rgb),0.12);
  --accent-soft-2: rgba(var(--accent-rgb),0.18);
  --accent-soft-3: rgba(var(--accent-rgb),0.24);
  --accent-border: rgba(var(--accent-rgb),0.28);
  --accent-border-2: rgba(var(--accent-rgb),0.18);
  --accent-border-3: rgba(var(--accent-rgb),0.35);
  --accent-ring: rgba(var(--accent-rgb),0.32);
  --accent-shadow: rgba(var(--accent-rgb),0.22);
  --accent-shadow-strong: rgba(var(--accent-rgb),0.30);
  --accent-strong-soft: rgba(var(--accent-rgb),0.55);

  --badge-verified: var(--accent);
  --badge-verified-border: var(--accent-border);
  --badge-admin: #FBBF24;
  --badge-admin-border: rgba(251,191,36,0.55);

  --danger: #F87171;
  --danger-rgb: 248,113,113;
  --danger-soft: rgba(var(--danger-rgb),0.16);
  --danger-border: rgba(var(--danger-rgb),0.32);
  --danger-border-strong: rgba(var(--danger-rgb),0.42);

  --success: #34D399;
  --success-rgb: 52,211,153;
  --success-soft: rgba(var(--success-rgb),0.16);

  --shadow-lg: 0 26px 70px rgba(0,0,0,0.45);
  --shadow-md: 0 16px 44px rgba(0,0,0,0.40);
  --shadow-sm: 0 10px 26px rgba(0,0,0,0.35);
}

/* ===== Reset ===== */
*,
*::before,
*::after{ box-sizing: border-box; }

html, body{ margin:0; padding:0; }

body{
  min-height: 100vh;
  padding-top: var(--header-h);
  overflow-x: hidden;
}

img{ display:block; max-width:100%; }
input, button, textarea{ font: inherit; }
a{ color: inherit; }

h1, h2, h3, .brand-name{
  font-family: "Fraunces", "Space Grotesk", serif;
}

/* ===== Soft grain (very subtle) ===== */
body::after{
  content:"";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.7' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='260' height='260' filter='url(%23n)' opacity='.20'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
  opacity: .06; /* riktigt lätt */
}

/* ===== Shared page wrapper ===== */
.page{
  max-width: 1120px;
  margin: 0 auto;
  padding: 26px 16px 78px;
}

/* ===== Glass utility ===== */
.glass{
  background: linear-gradient(180deg, var(--card), var(--card2));
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
}

/* =========================
   HEADER / NAV (Light glass)
========================= */
.site-header{
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--header-h);
  z-index: 1000;

  background: var(--nav-bg);
  backdrop-filter: blur(18px) saturate(170%);
  -webkit-backdrop-filter: blur(18px) saturate(170%);

  border-bottom: 1px solid var(--nav-border);
  box-shadow: var(--shadow-sm);
}

.site-header::before{
  content:"";
  position:absolute;
  left: 0; right: 0; top: 0;
  height: 1px;
  background: rgba(255,255,255,0.9);
  pointer-events:none;
}

.site-header .container{
  height: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;

  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
}

.left{ display:flex; align-items:center; gap: 12px; justify-self: start; }
.center{ flex: 1; }

/* Avatar/logo */
.avatar{
  width: 40px;
  height: 40px;
  border-radius: 999px;
  overflow: hidden;

  border: 1px solid var(--border);
  background: var(--surface-strong);
  box-shadow: var(--shadow-sm);
}
.avatar img{ width:100%; height:100%; object-fit: cover; }

/* Nav container */
.right{
  display:flex;
  align-items:center;
  gap: 10px;
  justify-self: center;
}

.header-actions{
  display:flex;
  align-items:center;
  gap: 10px;
  justify-self: end;
}

.auth-cta{
  height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  display:inline-flex;
  align-items:center;
  justify-content:center;

  background: var(--accent-soft);
  border: 1px solid var(--accent-border);
  color: var(--accent);

  font-weight: 900;
  font-size: 13px;
  letter-spacing: -0.01em;
  text-decoration: none;

  box-shadow: 0 10px 20px var(--accent-shadow);
  transition: transform var(--dur-1) var(--ease-pop),
              background var(--dur-1) var(--ease-out),
              box-shadow var(--dur-1) var(--ease-out);
}

.auth-cta .cta-long{ display:inline; }
.auth-cta .cta-short{ display:none; }

.auth-cta:hover{
  transform: translateY(-2px);
  background: var(--accent-soft-2);
  box-shadow: 0 14px 26px var(--accent-shadow);
}

.icon-btn.is-disabled{
  opacity: 0.55;
  cursor: not-allowed;
  filter: grayscale(0.3);
}

/* Nav button */
.icon-btn{
  height: 44px;
  min-width: 44px;
  display:inline-flex;
  align-items:center;
  justify-content:flex-start;
  gap: 10px;
  padding: 0 14px;

  background: var(--surface-strong);
  border: 1px solid var(--border);
  border-radius: 999px;

  text-decoration:none;
  cursor:pointer;

  box-shadow: var(--shadow-sm);
  transition: transform var(--dur-1) var(--ease-pop),
              background var(--dur-1) var(--ease-out),
              border-color var(--dur-1) var(--ease-out),
              box-shadow var(--dur-1) var(--ease-out);
}

.icon-btn svg{
  width: 20px;
  height: 20px;
  fill: none;
  stroke: var(--text-icon);
  stroke-width: 1.9;
}

.icon-btn::after{
  content: attr(title);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--text-icon);
  line-height: 1;
  white-space: nowrap;
}

.icon-btn:hover{
  transform: translateY(-2px);
  background: var(--nav-item-hover-bg);
  border-color: var(--nav-item-hover-border);
  box-shadow: var(--shadow-md);
}

.icon-btn.is-active{
  background: var(--accent-soft);
  border-color: var(--accent-border);
}
.icon-btn.is-active svg{ stroke: var(--accent); }
.icon-btn.is-active::after{ color: var(--accent); }

/* =========================
   PROFILE DROPDOWN
========================= */
.profile-menu{
  position: relative;
  display: inline-flex;
  align-items: center;
}

.profile-toggle{
  position: relative;
}

/* =========================
   Badges (admin / verified)
========================= */
.user-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width: 16px;
  height: 16px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  color: #fff;
  border: 1px solid transparent;
  box-shadow: var(--shadow-sm);
  user-select: none;
}

.user-badge[data-tooltip]{
  position: relative;
}

.user-badge[data-tooltip]::after{
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  top: -6px;
  transform: translate(-50%, -100%) scale(0.98);
  padding: 4px 8px;
  border-radius: 8px;
  background: var(--surface-stronger);
  color: var(--text-strong);
  border: 1px solid var(--border);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: -0.01em;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  box-shadow: var(--shadow-sm);
  transition: opacity var(--dur-1) var(--ease-out),
              transform var(--dur-1) var(--ease-pop);
  z-index: 2002;
}

.user-badge[data-tooltip]:hover::after,
.user-badge[data-tooltip]:focus-visible::after{
  opacity: 1;
  transform: translate(-50%, -110%) scale(1);
}

.user-badge.is-admin{
  background: var(--badge-admin);
  border-color: var(--badge-admin-border);
}

.user-badge.is-verified{
  background: var(--badge-verified);
  border-color: var(--badge-verified-border);
}

.profile-badge{
  position: absolute;
  top: -4px;
  right: -4px;
  pointer-events: none;
}

.profile-dropdown{
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 190px;

  display: grid;
  gap: 6px;
  padding: 10px;

  background: var(--surface-stronger);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow-md);

  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);

  opacity: 0;
  transform: translateY(-6px) scale(0.98);
  pointer-events: none;
  transition: opacity var(--dur-2) var(--ease-out),
              transform var(--dur-2) var(--ease-pop);
  z-index: 1002;
}

.profile-item{
  display:flex;
  align-items:center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;

  background: var(--surface-muted);
  border: 1px solid var(--border-soft);
  color: var(--text);
  text-decoration: none;
  font-weight: 900;
  font-size: 13px;
  letter-spacing: -0.01em;

  transition: transform var(--dur-1) var(--ease-pop),
              background var(--dur-1) var(--ease-out),
              border-color var(--dur-1) var(--ease-out),
              box-shadow var(--dur-1) var(--ease-out);
}

.profile-item:hover{
  transform: translateY(-1px);
  background: var(--surface-muted-3);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}

.profile-item.is-disabled{
  opacity: 0.6;
  cursor: not-allowed;
  filter: grayscale(0.2);
}

.profile-item.is-disabled:hover{
  transform: none;
  box-shadow: none;
  background: var(--surface-muted);
  border-color: var(--border-soft);
}

.profile-menu.is-open .profile-dropdown,
.profile-menu:focus-within .profile-dropdown{
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

@media (hover: hover) and (pointer: fine){
  .profile-menu:hover .profile-dropdown{
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
  }
}

/* Focus */
.icon-btn:focus-visible,
.menu-toggle:focus-visible{
  outline: 3px solid var(--accent-ring);
  outline-offset: 2px;
}

/* =========================
   HAMBURGER
========================= */
.menu-toggle{
  display:none;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: var(--surface-strong);
  border: 1px solid var(--border);
  cursor:pointer;
  align-items:center;
  justify-content:center;
  padding: 0;

  box-shadow: var(--shadow-sm);
  transition: transform var(--dur-1) var(--ease-pop),
              background var(--dur-1) var(--ease-out);
}
.menu-toggle:hover{ transform: translateY(-2px); background: var(--nav-item-hover-bg); }

.hamburger{
  position: relative;
  width: 22px;
  height: 2px;
  background: var(--text-strong);
  border-radius: 999px;
  display:block;
}
.hamburger::before,
.hamburger::after{
  content:"";
  position:absolute;
  left:0;
  width: 22px;
  height: 2px;
  background: var(--text-strong);
  border-radius: 999px;
  transition: transform var(--dur-2) var(--ease-out),
              top var(--dur-2) var(--ease-out),
              opacity var(--dur-2) var(--ease-out);
}
.hamburger::before{ top: -7px; }
.hamburger::after{ top: 7px; }

/* X state */
.menu-toggle[aria-expanded="true"] .hamburger{ background: transparent; }
.menu-toggle[aria-expanded="true"] .hamburger::before{ top:0; transform: rotate(45deg); }
.menu-toggle[aria-expanded="true"] .hamburger::after{ top:0; transform: rotate(-45deg); }

/* =========================
   MOBILE NAV (light dropdown)
========================= */
@media (max-width: 768px){
  .site-header .container{
    padding: 0 12px;
    grid-template-columns: auto 1fr auto;
  }
  .avatar{ width: 36px; height: 36px; }
  .menu-toggle{ display:inline-flex; order: 3; }
  .header-actions{ gap: 8px; }

.right{
    position: fixed;
    top: var(--header-h);
    left: 12px;
    right: 12px;

    flex-direction: column;
    align-items: stretch;
    gap: 8px;

    background: var(--surface-stronger);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 12px;

    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(16px) saturate(160%);
    -webkit-backdrop-filter: blur(16px) saturate(160%);

    opacity: 0;
    transform: translateY(-10px) scale(0.98);
    pointer-events: none;
    transition: opacity var(--dur-2) var(--ease-out),
                transform var(--dur-2) var(--ease-pop);
    z-index: 1001;
  }

  .right.active{
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
  }

  .icon-btn{
    width: 100%;
    border-radius: 16px;
    justify-content:flex-start;
    padding: 0 14px;
  }

  .profile-menu{
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .profile-dropdown{
    position: static;
    width: 100%;
    min-width: 0;
    margin-top: 6px;
    padding: 0 8px;
    background: var(--surface-muted);
    border-color: var(--border-soft);
    box-shadow: none;
    transform: none;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    pointer-events: none;
    transition: opacity var(--dur-2) var(--ease-out),
                max-height var(--dur-2) var(--ease-out),
                padding var(--dur-2) var(--ease-out);
  }

  .profile-menu.is-open .profile-dropdown,
  .profile-menu:focus-within .profile-dropdown{
    opacity: 1;
    max-height: 240px;
    padding: 8px;
    pointer-events: auto;
  }

  .profile-item{
    background: var(--surface-strong);
    border-color: var(--border-soft);
  }
}

@media (max-width: 520px){
  .icon-btn::after{ display:none; }
  .icon-btn{ width: 44px; padding: 0; justify-content:center; border-radius: 999px; }
  .auth-cta{ height: 36px; padding: 0 10px; font-size: 12px; }
  .auth-cta .cta-long{ display:none; }
  .auth-cta .cta-short{ display:inline; }
  .brand-name{ font-size: 13px; }
}

/* =========================
   Entrance animations
========================= */
@keyframes pageIn{
  from{ opacity: 0; transform: translateY(14px) scale(0.985); filter: blur(6px); }
  to{ opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}

.page, .hem-main, .profil-main{
  animation: pageIn var(--dur-3) var(--ease-out) both;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce){
  *{ animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ===== Brand in header ===== */
.brand{
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;

  text-decoration: none;
  color: var(--text);
  line-height: 1.05;
  min-width: 0;
}

.brand-name{
  font-weight: 950;
  letter-spacing: -0.02em;
  font-size: 14px;
  color: var(--text-strong);
  white-space: nowrap;
}

.brand-tag{
  font-size: 12px;
  font-weight: 650;
  color: var(--text-muted);
  white-space: nowrap;
}

@media (max-width: 520px){
  .brand-tag{ display:none; }
}

/* =========================
   Cookie banner
========================= */
.cookie-banner{
  position: fixed;
  left: 18px;
  right: 18px;
  bottom: 18px;
  z-index: 1500;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;

  background: rgba(10,15,22,0.92);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.cookie-banner[hidden]{
  display: none !important;
}

.cookie-banner p{
  margin: 0;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.45;
}

.cookie-banner button{
  background: #fff;
  color: #0b1117;
  padding: 8px 14px;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 900;
  font-size: 13px;
  box-shadow: 0 10px 18px rgba(0,0,0,0.18);
  transition: transform var(--dur-1) var(--ease-pop),
              opacity var(--dur-1) var(--ease-out);
}

.cookie-banner button:hover{
  opacity: 0.9;
  transform: translateY(-1px);
}

:root[data-theme="dark"] .cookie-banner{
  background: rgba(6,10,16,0.95);
  border-color: rgba(148,163,184,0.22);
}

@media (max-width: 520px){
  .cookie-banner{
    flex-direction: column;
    align-items: stretch;
  }
  .cookie-banner button{
    width: 100%;
    text-align: center;
  }
}











