/* css/custom.css */
/* Premium Custom Style Overrides for Eraniyan Pyro Park (Light Theme + Purple Accents) */

/* Glass panel background */
.glass-panel {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(226, 232, 240, 0.8);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.04);
}

/* Glow Cards hover animations */
.glow-card {
  position: relative;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: #ffffff;
  border: 1px solid #e2e8f0;
}

.glow-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px -15px rgba(124, 58, 237, 0.12);
  border-color: rgba(124, 58, 237, 0.3);
}

/* Glowing buttons (Purple/Indigo Theme) */
.glow-button {
  background: linear-gradient(135deg, #7c3aed 0%, #4f46e5 100%);
  box-shadow: 0 4px 18px 0 rgba(124, 58, 237, 0.3);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.glow-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px 0 rgba(124, 58, 237, 0.45);
  opacity: 0.95;
}

/* Secondary Button (Pink/Magenta accent) */
.accent-button {
  background: linear-gradient(135deg, #ec4899 0%, #d946ef 100%);
  box-shadow: 0 4px 18px 0 rgba(236, 72, 153, 0.3);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.accent-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px 0 rgba(236, 72, 153, 0.45);
  opacity: 0.95;
}

/* Indigo buttons for super admin theme */
.indigo-glow-button {
  background: linear-gradient(135deg, #6610f2 0%, #e83e8c 100%);
  box-shadow: 0 4px 18px 0 rgba(102, 16, 242, 0.3);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.indigo-glow-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px 0 rgba(102, 16, 242, 0.45);
  opacity: 0.95;
}

/* Brand gradient text */
.brand-text-gradient {
  background: linear-gradient(135deg, #7c3aed 0%, #ec4899 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Custom fade animation */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
  animation: fadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Custom pulsing glow */
@keyframes pulseGlow {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 0.9; }
}

.animate-pulse-glow {
  animation: pulseGlow 3s infinite ease-in-out;
}

/* Custom scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: #2E134E;
}
::-webkit-scrollbar-thumb {
  background: #7c3aed;
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: #a855f7;
}

/* Floating Sidebar styles */
.floating-sidebar {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  z-index: 50;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: rgba(46,19,78,0.85);
  padding: 12px 8px;
  border-radius: 20px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(124,58,237,0.4);
  backdrop-filter: blur(12px);
}
.floating-sidebar.left {
  left: 15px;
}
.floating-sidebar.right {
  right: 15px;
}
.floating-sidebar-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  transition: all 0.2s ease-in-out;
}
.floating-sidebar-icon:hover {
  transform: scale(1.1);
}

/* Auto hide placeholder on focus globally across the entire project */
input:focus::placeholder,
textarea:focus::placeholder {
  color: transparent !important;
  opacity: 0 !important;
}

/* ════════════════════════════════════════════════════════
  .inv-card {
  background: #fff;
  overflow: hidden;
  border: 2px solid #0f172a;
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0,0,0,.03);
}
.inv-head {
  background: transparent;
  color: #0f172a;
  padding: 18px 24px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  position: relative;
  border-bottom: 2px solid #0f172a;
  margin: 0;
}
.inv-head .co-name {
  font-size: 18px; font-weight: 900;
  letter-spacing: -.02em; margin: 0 0 3px; line-height: 1.1;
  color: #0f172a;
}
.inv-head .co-sub {
  font-size: 10px; font-weight: 700; color: #475569;
  text-transform: uppercase; letter-spacing: .08em;
}
.inv-head .co-detail {
  margin-top: 8px; font-size: 10px; color: #475569; line-height: 1.6;
}
.inv-head .co-detail strong {
  color: #0f172a;
}
.inv-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
  flex-shrink: 0;
}
.inv-meta .inv-id {
  font-size: 18px; font-weight: 900;
  font-family: monospace; line-height: 1.1;
  color: #0f172a;
}
.inv-meta .inv-date { font-size: 10px; color: #475569; margin-top: 2px; }
.inv-meta .inv-badge {
  display: inline-block; margin-top: 6px;
  padding: 3px 10px; border-radius: 999px;
  font-size: 9px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .08em;
  background: transparent;
  border: 1.5px solid #0f172a;
  color: #0f172a;
  white-space: nowrap;
}

/* Status row */
.inv-status-row {
  display: flex; gap: 10px;
  padding: 13px 28px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  flex-wrap: wrap; align-items: center;
}
.schip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 5px 12px; border-radius: 999px;
  font-size: 10px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .07em;
  border: 1px solid;
}
.schip-purple { background:#faf5ff; color:#7e22ce; border-color:#e9d5ff; }
.schip-mid    { background:#f8fafc; color:#475569; border-color:#cbd5e1; }
.schip-light  { background:#f8fafc; color:#64748b; border-color:#e2e8f0; }
.schip-dot { width:6px;height:6px;border-radius:50%;background:currentColor;flex-shrink:0; }

/* Parties */
.inv-parties {
  display: grid; grid-template-columns: 1fr 1fr;
  border-bottom: 2px solid #0f172a;
}
.inv-party { padding: 16px 24px; }
.inv-party:first-child { border-right: 2px solid #0f172a; }
.inv-party-lbl {
  font-size: 9px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .12em;
  color: #475569; margin-bottom: 6px;
}
.inv-party-name {
  font-size: 14px; font-weight: 900; color: #0f172a; margin-bottom: 4px;
}
.inv-party-detail {
  font-size: 11px; color: #475569; font-weight: 600; line-height: 1.7;
}
.inv-party-detail span { color: #0f172a; font-weight: 700; }

/* Items table */
.inv-tbl-wrap { padding: 16px 24px; border-bottom: 2px solid #0f172a; }
.inv-tbl-wrap h4 {
  font-size: 10px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .1em;
  color: #0f172a; margin: 0 0 10px;
}
table.inv-tbl {
  width: 100%; border-collapse: collapse; font-size: 12px;
}
table.inv-tbl thead tr {
  background: transparent;
  color: #0f172a;
}
table.inv-tbl th {
  padding: 10px 12px;
  font-size: 9px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .09em;
  white-space: nowrap;
  color: #0f172a;
  background: transparent;
  border-bottom: 2px solid #0f172a;
  border-top: 1px solid #cbd5e1;
}
table.inv-tbl th:first-child { border-radius: 0; }
table.inv-tbl th:last-child  { border-radius: 0; }
table.inv-tbl tbody tr:nth-child(even) { background: #f8fafc; }
table.inv-tbl td {
  padding: 9px 12px;
  border-bottom: 1px solid #e2e8f0;
  color: #334155; font-weight: 600;
}
table.inv-tbl td.num    { text-align: right; font-family: monospace; }
table.inv-tbl td.center { text-align: center; }
table.inv-tbl td.name   { font-weight: 700; color: #0f172a; }
.strike { text-decoration: line-through; color: #94a3b8; font-size: 11px; }
.disc-pct { color: #0f172a; font-weight: 800; }

/* Footer grid */
.inv-footer-grid {
  display: grid; grid-template-columns: 1.2fr 1fr;
  border-bottom: 2px solid #0f172a;
}
.inv-bank {
  padding: 16px 24px;
  border-right: 2px solid #0f172a;
}
.inv-bank h5 {
  font-size: 10px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .1em;
  color: #0f172a;
  text-decoration: underline;
  margin: 0 0 10px;
}
.brow {
  display: flex; gap: 8px;
  font-size: 11px; color: #475569; line-height: 1.9;
}
.brow .bl { width: 90px; flex-shrink: 0; }
.brow .bv { font-weight: 700; color: #0f172a; font-family: monospace; }
.upi-section {
  margin-top: 12px; padding-top: 10px;
  border-top: 1px dashed #0f172a;
  display: flex; gap: 12px; align-items: center;
}
.upi-section img {
  width: 56px; height: 56px; object-fit: contain;
  border: 1px solid #cbd5e1; border-radius: 8px; background: #fff;
}
.upi-label { font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; color: #0f172a; margin-bottom: 4px; }
.upi-val   { font-size: 10px; font-weight: 700; font-family: monospace; color: #0f172a; }

.inv-totals { padding: 16px 24px; }
.trow {
  display: flex; justify-content: space-between;
  align-items: center; font-size: 12px;
  padding: 5px 0; color: #475569; font-weight: 600;
}
.trow .tv { font-family: monospace; font-weight: 700; color: #0f172a; }
.trow.savings .tv { color: #334155; font-weight: 900; }
.trow.grand {
  margin-top: 10px; padding: 10px 16px !important;
  background: transparent;
  border: 2px solid #0f172a;
  border-radius: 8px; color: #0f172a;
  font-size: 14px; font-weight: 900;
}
.trow.grand .tv { color: #0f172a; font-size: 18px; }

/* Footer strip */
.inv-strip {
  background: transparent;
  color: #0f172a;
  border-top: none;
  padding: 10px 24px;
  font-size: 10px; font-weight: 600;
  display: flex; justify-content: space-between;
  align-items: center;
  flex-wrap: wrap; gap: 6px;
}
.inv-strip .note { font-style: italic; color: #334155; }
.inv-strip .seal { font-family: monospace; color: #334155; font-size: 9px; }

/* Off-screen wrapper for rendering printable invoices and PDF generation */
.print-area-wrapper {
  height: 0;
  overflow: hidden;
  position: relative;
}
.print-area-container {
  width: 800px;
  background: #ffffff;
}

/* Force background colors and styles in print preview */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
  }
  header, footer, .floating-sidebar, .print\:hidden, select, input, button, #site-top-fixed, #header-spacer, main, aside {
    display: none !important;
  }
  /* Show only print areas */
  .print-area-wrapper {
    height: auto !important;
    overflow: visible !important;
  }
  .print-area-container {
    position: static !important;
    left: auto !important;
    top: auto !important;
    width: 100% !important;
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
  }
  .inv-card {
    border: 2px solid #0f172a !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
    overflow: hidden !important;
  }
  /* ── Header ── */
  .inv-head {
    background: transparent !important;
    color: #0f172a !important;
    border: none !important;
    border-bottom: 2px solid #0f172a !important;
    border-radius: 0 !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: flex-start !important;
  }
  .inv-head .co-name,
  .inv-head .co-sub,
  .inv-head .co-detail,
  .inv-head .co-detail strong,
  .inv-meta .inv-id {
    color: #0f172a !important;
  }
  .inv-meta {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;
    text-align: right !important;
    flex-shrink: 0 !important;
  }
  .inv-meta .inv-date {
    color: #475569 !important;
  }
  .inv-meta .inv-badge {
    display: none !important;
  }
  .inv-parties {
    border-bottom: 2px solid #0f172a !important;
  }
  .inv-party:first-child {
    border-right: 2px solid #0f172a !important;
  }
  .inv-tbl-wrap {
    border-bottom: 2px solid #0f172a !important;
  }
  table.inv-tbl thead tr {
    background: transparent !important;
    color: #0f172a !important;
  }
  table.inv-tbl th {
    color: #0f172a !important;
    background: transparent !important;
    border-bottom: 2px solid #0f172a !important;
  }
  .inv-footer-grid {
    border-bottom: 2px solid #0f172a !important;
  }
  .inv-bank {
    border-right: 2px solid #0f172a !important;
  }
  .trow.grand {
    background: transparent !important;
    border: 2px solid #0f172a !important;
    border-radius: 8px !important;
    color: #0f172a !important;
    padding: 10px 16px !important;
  }
  .trow.grand .tv {
    color: #0f172a !important;
  }
  .inv-strip {
    background: transparent !important;
    border-top: none !important;
  }
  .inv-strip .note,
  .inv-strip .seal {
    color: #0f172a !important;
  }
  .inv-card * {
    print-color-adjust: exact !important;
    -webkit-print-color-adjust: exact !important;
  }
  /* Prevent page breaks inside the invoice card */
  .inv-card {
    page-break-inside: avoid !important;
    break-inside: avoid !important;
    max-height: 100% !important;
  }
  /* Compact print layout to fit on single page */
  .inv-head {
    padding: 16px 20px 12px !important;
  }
  .inv-party {
    padding: 12px 20px !important;
  }
  .inv-tbl-wrap {
    padding: 12px 20px !important;
  }
  table.inv-tbl th {
    padding: 8px 10px !important;
  }
  table.inv-tbl td {
    padding: 6px 10px !important;
  }
  .inv-footer-grid {
    padding: 12px 20px !important;
    gap: 15px !important;
  }
  .inv-strip {
    padding: 8px 20px !important;
  }
  @page {
    size: A4 portrait;
    margin: 8mm 10mm;
    /* Suppress browser running header & footer text via named margin boxes */
    @top-left   { content: ""; }
    @top-center { content: ""; }
    @top-right  { content: ""; }
    @bottom-left   { content: ""; }
    @bottom-center { content: ""; }
    @bottom-right  { content: ""; }
  }
}



