/* === Wedding Color Palette (edit these hex codes to adjust shades) === */
:root {
  --login-bg: #fceef1;        /* light blush pink for login page */
  --upload-bg: #fbf9f5;       /* warm ivory for upload & gallery page */
  --green-dark: #2d4f38;      /* deep sage/forest green */
  --green-mid: #4a7856;       /* medium sage */
  --green-soft: #eef4ef;      /* soft sage tint */
  --pink-soft: #fdf5f7;       /* soft blush tint for dropzone */
  --pink-accent: #d48c99;     /* dusty rose accent */
  --pink-border: #edd2d8;     /* delicate blush border */
  --ivory-border: #e9e2d6;    /* soft warm border for ivory page */
  --card-bg: #ffffff;
  --text-muted: #6b726d;

  --font-main: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
}

/* === Base Page Styling === */
html, body {
  margin: 0 !important;
  padding: 0 !important;
  min-height: 100vh !important;
  color: var(--green-dark) !important;
  font-family: var(--font-main) !important;
}

/* =========================================================
   1. LOGIN SCREEN (Light Pink Background)
   ========================================================= */
html#ht_spl,
html#ht_spl body {
  background: var(--login-bg) !important;
}

html#ht_spl body {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 20px !important;
  box-sizing: border-box !important;
  opacity: 1 !important;
  transition: opacity 0.15s ease;
}

html#ht_spl #a,
html#ht_spl #v,
html#ht_spl #b,
html#ht_spl #f,
html#ht_spl #f + ul,
html#ht_spl #l,
html#ht_spl #w,
html#ht_spl #cc,
html#ht_spl .agr,
html#ht_spl .agr + ul,
html#ht_spl #repl,
html#ht_spl #pb,
html#ht_spl #tth {
  display: none !important;
}

html#ht_spl #wrap {
  width: 100% !important;
  max-width: 430px !important;
  margin: 0 auto !important;
  padding: 38px 28px 40px !important;
  background: var(--card-bg) !important;
  border: 1.5px solid var(--pink-border) !important;
  border-radius: 20px !important;
  box-shadow: 0 16px 40px rgba(45, 79, 56, 0.08) !important;
  text-align: center !important;
  box-sizing: border-box !important;
}

/* Couple Photo */
html#ht_spl #wrap::before {
  content: "";
  display: block;
  width: 140px;
  height: 140px;
  margin: 0 auto 20px;
  border-radius: 50%;
  border: 3px solid var(--pink-border);
  outline: 4px solid var(--login-bg);
  box-shadow: 0 8px 20px rgba(45, 79, 56, 0.12);
  background: url("/static/couple.JPG") center / cover no-repeat;
}

/* Welcome Heading */
html#ht_spl #wrap > div::before {
  content: "Welcome to Emilie and Markus' Photo Gallery";
  display: block;
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
  color: var(--green-dark);
  margin-bottom: 10px;
}

/* Subtitle */
html#ht_spl #lf::before {
  content: "Enter the gallery login below to share & view photos";
  display: block;
  font-size: 0.96rem;
  color: var(--text-muted);
  margin-bottom: 22px;
}

html#ht_spl #lf {
  display: flex !important;
  flex-direction: column !important;
  gap: 12px !important;
  width: 100% !important;
}

html#ht_spl #lu,
html#ht_spl #lp {
  width: 100% !important;
  padding: 15px 16px !important;
  font-size: 16px !important;
  font-family: var(--font-main) !important;
  color: var(--green-dark) !important;
  background: #fafafa !important;
  border: 1.5px solid var(--pink-border) !important;
  border-radius: 12px !important;
  outline: none !important;
  box-sizing: border-box !important;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

html#ht_spl #lu:focus,
html#ht_spl #lp:focus {
  background: #ffffff !important;
  border-color: var(--green-mid) !important;
  box-shadow: 0 0 0 3px rgba(74, 120, 86, 0.15) !important;
}

html#ht_spl #ls {
  width: 100% !important;
  padding: 15px 18px !important;
  font-size: 1.05rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.04em !important;
  color: #ffffff !important;
  background: var(--green-dark) !important;
  border: none !important;
  border-radius: 12px !important;
  cursor: pointer !important;
  transition: background-color 0.2s ease, transform 0.1s ease;
}

html#ht_spl #ls:hover {
  background: var(--pink-accent) !important;
}

html#ht_spl #ls:active {
  transform: scale(0.99);
}

html#ht_spl #lm {
  font-size: 0.95rem;
  color: #b44354;
  min-height: 1.2em;
}

/* =========================================================
   2. UPLOAD & GALLERY SCREEN (Ivory Background)
   ========================================================= */
html#ht_brw:has(body[perms*="read"][perms*="write"]:not([perms*="delete"])),
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) {
  background: var(--upload-bg) !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 24px !important;
  padding: 28px 16px 84px !important;
  box-sizing: border-box !important;
  opacity: 1 !important;
  transition: opacity 0.15s ease;
}

/* Hide technical controls, extra toolbar buttons & table headers for guests */
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) .ayjump,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2conf td.c,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2conf #u2c3w,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2etaw,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2cards,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2tab thead,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #tth,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #rcm,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #wfp,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #repl,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #bdoc,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #widget,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead #gridsel,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead #gridvau,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead #gridcrop,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead #grid3x,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead > span:nth-of-type(1),
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead > span:nth-of-type(2),
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead a[s="sz"],
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead a[s="ext"] {
  display: none !important;
}

/* Upload Card */
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #op_up2k {
  position: static !important;
  display: block !important;
  width: 100% !important;
  max-width: 720px !important;
  margin: 0 auto !important;
  padding: 34px 24px !important;
  background: var(--card-bg) !important;
  border: 1.5px solid var(--ivory-border) !important;
  border-radius: 20px !important;
  box-shadow: 0 12px 32px rgba(45, 79, 56, 0.06) !important;
  text-align: center !important;
  box-sizing: border-box !important;
}

/* Event Pill Badge */
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2form::before {
  content: "E & M  •  APRIL 2027";
  display: inline-block;
  padding: 5px 14px;
  margin-bottom: 14px;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green-dark);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2form {
  display: block !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2form > div {
  display: none !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #op_up2k::before {
  content: "Share Your Photos with Emilie & Markus";
  display: block;
  font-family: var(--font-serif);
  font-size: 2.05rem;
  font-weight: 700;
  line-height: 1.2;
  color: var(--green-dark);
  margin: 0 0 8px 0;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2conf::before {
  content: "Tap below to choose photos or videos from your phone";
  display: block;
  font-size: 0.98rem;
  line-height: 1.4;
  color: var(--text-muted);
  margin: 0 0 22px 0;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2conf,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2conf tbody,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2conf tr,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2btn_cw {
  display: block !important;
  float: none !important;
  width: 100% !important;
  max-width: none !important;
  margin: 0 auto !important;
  padding: 0 !important;
  border: none !important;
  background: transparent !important;
  box-sizing: border-box !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2btn {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 12px !important;
  float: none !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  min-height: 165px !important;
  margin: 0 auto !important;
  padding: 26px 20px !important;
  background: var(--pink-soft) !important;
  border: 2px dashed var(--pink-accent) !important;
  border-radius: 16px !important;
  color: var(--green-dark) !important;
  font-family: var(--font-main) !important;
  font-size: 0.98rem !important;
  line-height: 1.5 !important;
  text-align: center !important;
  cursor: pointer !important;
  box-sizing: border-box !important;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.1s ease;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2btn:hover,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2btn:focus {
  background: var(--green-soft) !important;
  border-color: var(--green-dark) !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2bm {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: auto !important;
  max-width: none !important;
  padding: 12px 30px !important;
  margin: 0 !important;
  background: var(--green-dark) !important;
  color: #ffffff !important;
  border-radius: 999px !important;
  font-size: 0.98rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.08em !important;
  white-space: nowrap !important;
  text-shadow: none !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2bm sup {
  color: #ffffff !important;
  font-size: 0.98rem !important;
  font-weight: 600 !important;
  vertical-align: baseline !important;
  text-shadow: none !important;
}

/* Thank-You Banner */
.wedding-thanks {
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--green-soft);
  color: var(--green-dark);
  border: 1px solid #cfe0d2;
  font-size: 0.95rem;
  font-weight: 500;
}

/* Cleaner Mobile Upload Queue Cards */
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2tabw {
  margin-top: 18px !important;
  width: 100% !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2tab {
  width: 100% !important;
  border-collapse: separate !important;
  border-spacing: 0 8px !important;
  font-size: 0.9rem !important;
  text-align: left !important;
  color: var(--green-dark) !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2tab tbody tr {
  background: var(--upload-bg) !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2tab tbody td {
  padding: 10px 12px !important;
  border-top: 1px solid var(--ivory-border) !important;
  border-bottom: 1px solid var(--ivory-border) !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2tab tbody td:first-child {
  border-left: 1px solid var(--ivory-border) !important;
  border-radius: 10px 0 0 10px !important;
  word-break: break-word;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #u2tab tbody td:last-child {
  border-right: 1px solid var(--ivory-border) !important;
  border-radius: 0 10px 10px 0 !important;
  text-align: right;
  font-weight: 600;
}

/* Gallery Card Below Upload Box */
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #wrap {
  display: block !important;
  width: 100% !important;
  max-width: 980px !important;
  margin: 0 auto !important;
  padding: 28px 20px !important;
  background: var(--card-bg) !important;
  border: 1.5px solid var(--ivory-border) !important;
  border-radius: 20px !important;
  box-shadow: 0 12px 32px rgba(45, 79, 56, 0.06) !important;
  box-sizing: border-box !important;
  text-align: center !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #wrap::before {
  content: "Wedding Gallery";
  display: block;
  font-family: var(--font-serif);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--green-dark);
  text-align: center;
  margin-bottom: 14px;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead {
  background: transparent !important;
  border-bottom: 1px solid var(--ivory-border) !important;
  padding-bottom: 12px !important;
  margin-bottom: 16px !important;
  text-align: center !important;
  font-size: 0.9rem !important;
  color: var(--text-muted) !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead a {
  border-radius: 999px !important;
  padding: 4px 12px !important;
  margin: 0 2px !important;
  color: var(--green-dark) !important;
  text-decoration: none !important;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead a.on,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead a.s0,
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ghead a.s1 {
  background: var(--green-dark) !important;
  color: #ffffff !important;
}

/* Thumbnail Grid Polish */
html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ggrid a {
  border-radius: 12px !important;
  overflow: hidden !important;
  border: 1px solid var(--ivory-border) !important;
  box-shadow: 0 4px 14px rgba(45, 79, 56, 0.06) !important;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

html#ht_brw body[perms*="read"][perms*="write"]:not([perms*="delete"]) #ggrid a:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(45, 79, 56, 0.12) !important;
}

/* Floating + Upload Pill Button */
.wedding-fab {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 999;
  padding: 13px 20px;
  border: none;
  border-radius: 999px;
  background: var(--green-dark);
  color: #ffffff;
  font-family: var(--font-main);
  font-size: 0.95rem;
  font-weight: 600;
  box-shadow: 0 8px 24px rgba(45, 79, 56, 0.25);
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.1s ease;
}

.wedding-fab:hover {
  background: var(--pink-accent);
}

.wedding-fab:active {
  transform: scale(0.97);
}

/* Subtle Sign Out Link */
.wedding-signout {
  margin-top: 8px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-main);
  font-size: 0.88rem;
  text-decoration: underline;
  cursor: pointer;
}

.wedding-signout:hover {
  color: var(--green-dark);
}