/* ============================================================
   CC PhotoStore — Global Responsive Stylesheet
   Breakpoints: 480 / 768 / 1024 / 1280
   ============================================================ */

/* ── Google Fonts ── */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,wght@0,300;0,400;0,500;0,700;1,300&family=DM+Serif+Display&display=swap');

/* ── CSS Variables ── */
:root {
  --bg:         #0e0e0e;
  --bg-card:    #161616;
  --bg-input:   #111;
  --border:     #242424;
  --border-mid: #2e2e2e;
  --text:       #e8e8e8;
  --text-muted: #777;
  --text-dim:   #444;
  --accent:     #8ec5fc;
  --accent2:    #e0c3fc;
  --grad:       linear-gradient(135deg, #8ec5fc, #e0c3fc);
  --grad-rev:   linear-gradient(135deg, #e0c3fc, #8ec5fc);
  --green:      #4caf50;
  --red:        #f44;
  --wa:         #25d366;
  --radius:     10px;
  --radius-lg:  16px;
  --nav-h:      62px;
  --shadow:     0 4px 24px rgba(0,0,0,.5);
  --font:       'DM Sans', 'Noto Sans SC', system-ui, sans-serif;
  --font-serif: 'DM Serif Display', serif;
  --trans:      .22s cubic-bezier(.4,0,.2,1);
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
img { display: block; max-width: 100%; }
a   { color: inherit; }
button, input, select, textarea { font-family: inherit; }

/* ── Film-grain overlay ── */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background: url("https://www.transparenttextures.com/patterns/asfalt-light.png");
  opacity: .03;
  pointer-events: none;
  z-index: 9999;
}

/* ============================================================
   NAVBAR
   ============================================================ */
.navbar {
  position: sticky;
  top: 0;
  z-index: 900;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(16px, 4vw, 48px);
  height: var(--nav-h);
  background: rgba(10,10,10,.95);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.navbar .logo {
  font-family: var(--font-serif);
  font-size: clamp(18px, 3vw, 24px);
  letter-spacing: 1px;
  background: var(--grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-decoration: none;
  flex-shrink: 0;
}

/* Desktop nav links */
.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(8px, 2vw, 28px);
}
.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .3px;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: color var(--trans), border-color var(--trans);
  white-space: nowrap;
}
.nav-links a:hover,
.nav-links a.active { color: #fff; border-bottom-color: var(--accent); }

/* Hamburger button */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: 1px solid var(--border-mid);
  border-radius: 8px;
  cursor: pointer;
  padding: 8px;
  transition: background var(--trans);
}
.nav-toggle:hover { background: var(--bg-card); }
.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform var(--trans), opacity var(--trans);
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile drawer */
.nav-drawer {
  display: none;
  position: fixed;
  top: var(--nav-h);
  left: 0; right: 0;
  background: rgba(10,10,10,.98);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(16px);
  z-index: 850;
  padding: 16px 24px 24px;
  animation: slideDown .2s ease;
}
.nav-drawer.open { display: block; }
.nav-drawer a {
  display: block;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
  transition: color var(--trans), padding-left var(--trans);
}
.nav-drawer a:last-child { border-bottom: none; }
.nav-drawer a:hover { color: #fff; padding-left: 8px; }

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Footer ── */
.site-footer {
  text-align: center;
  padding: clamp(32px, 6vw, 56px) clamp(16px, 4vw, 40px) 24px;
  background: #000;
  border-top: 1px solid var(--border);
}
.site-footer h2 {
  font-weight: 300;
  font-size: clamp(18px, 3vw, 24px);
  color: #fff;
  margin: 0 0 20px;
  letter-spacing: 1px;
}
.social-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: clamp(16px, 3vw, 32px);
  margin: 20px 0;
}
.social-links a {
  font-size: clamp(22px, 4vw, 30px);
  color: var(--text-muted);
  text-decoration: none;
  transition: color var(--trans), transform var(--trans);
}
.social-links a:hover { color: #fff; transform: scale(1.2) translateY(-2px); }
.copyright { font-size: 13px; color: var(--text-dim); margin-top: 12px; }

/* ============================================================
   BUTTONS & INPUTS  (shared)
   ============================================================ */
.btn-grad {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  background: var(--grad);
  color: #111;
  font-weight: 700;
  font-size: 14px;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  transition: transform var(--trans), box-shadow var(--trans);
  white-space: nowrap;
}
.btn-grad:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(142,197,252,.3);
}
.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: transparent;
  border: 1px solid var(--border-mid);
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  transition: background var(--trans), border-color var(--trans);
}
.btn-outline:hover { background: var(--bg-card); border-color: var(--accent); }

.field {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 14px;
}
.field label {
  font-size: 13px;
  color: #bbb;
  font-weight: 500;
}
.field label .req { color: #ff8a8a; margin-left: 2px; }
.field input,
.field textarea,
.field select {
  padding: 10px 13px;
  background: var(--bg-input);
  border: 1px solid var(--border-mid);
  color: var(--text);
  border-radius: 8px;
  font-size: 14px;
  transition: border-color var(--trans);
  width: 100%;
}
.field input:focus,
.field textarea:focus,
.field select:focus {
  outline: none;
  border-color: var(--accent);
}
.field textarea { resize: vertical; min-height: 72px; }

/* Alert */
.alert {
  padding: 13px 18px;
  border-radius: var(--radius);
  font-size: 14px;
  line-height: 1.5;
  margin-bottom: 16px;
}
.alert-success { background:#1a3a1a; border:1px solid var(--green); color:#90ee90; }
.alert-warning  { background:#3a3000; border:1px solid #ffd700;    color:#ffe066; }
.alert-error    { background:#3a1a1a; border:1px solid var(--red); color:#ff8a8a; }

.tbl-wrap,
.tbl-wrap table,
.tbl-wrap thead,
.tbl-wrap tbody,
.tbl-wrap tr,
.tbl-wrap td,
.tbl-wrap th{
  position:static !important;
  float:none !important;
  transform:none !important;
}

.tbl-wrap table{
  display:table !important;
  width:100% !important;
  border-collapse:collapse !important;
}

.tbl-wrap thead{
  display:table-header-group !important;
}

.tbl-wrap tbody{
  display:table-row-group !important;
}

.tbl-wrap tr{
  display:table-row !important;
  visibility:visible !important;
  opacity:1 !important;
}

.tbl-wrap td,
.tbl-wrap th{
  display:table-cell !important;
}

.order-cards{
  display:none !important;
}

/* ============================================================
   RESPONSIVE HELPERS
   ============================================================ */
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }
.section    { padding: clamp(32px, 6vw, 64px) 0; }

/* Mobile: <768 */
@media (max-width: 767px) {
  .nav-links   { display: none; }
  .nav-toggle  { display: flex; }
}
/* Tablet+: ≥768 */
@media (min-width: 768px) {
  .nav-toggle  { display: none; }
  .nav-drawer  { display: none !important; }
}

/* ── Phosphor Icon global tweaks ──────────────────────────────
   Ensures ph icons align well inline with text everywhere     */
i.ph {
  display: inline-flex;
  align-items: center;
  line-height: 1;
  vertical-align: middle;
  position: relative;
  top: -1px;
}

/* Nav links: slightly larger */
nav a i.ph, .nav-link i.ph { font-size: 1.05em; }

/* Button icons: match button text */
button i.ph, .btn-grad i.ph, .btn-sm i.ph { font-size: 1em; }

/* Alert / badge icons: subtle offset */
.alert i.ph, .err i.ph { font-size: 1em; top: -1px; }

/* Track page step circles */
.step-circle i.ph { font-size: 18px; top: 0; }

/* Hint icon in track.php */
.hint-icon i.ph { font-size: 52px; display: block; }

/* Admin sidebar/nav icons */
.logo i.ph   { font-size: 1.1em; }
.sidebar a i.ph, nav a i.ph { margin-right: 2px; }

/* Product page: upload area icon */
.upload-placeholder i.ph { font-size: 40px; }

/* Payment method card icons */
.method-icon i.ph { font-size: 30px; top: 0; }

/* Status badges */
.badge i.ph { font-size: 0.9em; }

/* Summary/details expand */
summary i.ph { font-size: 0.95em; }

/* h2, h3, h4 heading icons */
h2 i.ph, h3 i.ph, h4 i.ph {
  font-size: 0.9em;
  margin-right: 4px;
  opacity: 0.85;
}
