/* ===== Vylon Agency Admin Portal CSS ===== */
/* Premium Dark Theme with Gold Accents */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ===== CSS Variables ===== */
:root {
  --bg-primary: #0a0e17;
  --bg-secondary: #0d1321;
  --bg-card: #111827;
  --bg-card-hover: #16213a;
  --bg-sidebar: #0b1020;
  --bg-input: #151d30;

  --gold-primary: #c9a44e;
  --gold-light: #f0d78c;
  --gold-dark: #9a7a30;
  --gold-gradient: linear-gradient(135deg, #c9a44e, #f0d78c);

  --text-primary: #f0f2f5;
  --text-secondary: #8b95a8;
  --text-muted: #4a5568;

  --border-color: rgba(201, 164, 78, 0.12);
  --border-light: rgba(255, 255, 255, 0.06);

  --green: #10b981;
  --blue: #3b82f6;
  --red: #ef4444;
  --purple: #8b5cf6;
  --orange: #f59e0b;

  --sidebar-width: 260px;
  --sidebar-collapsed: 72px;
  --topbar-height: 70px;
  --radius: 14px;
  --radius-sm: 8px;
  --radius-lg: 20px;

  --shadow-sm: 0 2px 8px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 20px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.5);
  --shadow-gold: 0 4px 20px rgba(201, 164, 78, 0.15);
}

/* ===== Login Screen ===== */
.login-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.login-overlay.hidden {
  opacity: 0;
  transform: scale(1.05);
  pointer-events: none;
}

/* Floating Particles */
.login-particles {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.particle {
  position: absolute;
  background: var(--gold-primary);
  border-radius: 50%;
  opacity: 0.15;
  animation: floatParticle linear infinite;
}

@keyframes floatParticle {
  0% { transform: translateY(0) translateX(0); opacity: 0; }
  10% { opacity: 0.2; }
  50% { opacity: 0.1; }
  90% { opacity: 0.15; }
  100% { transform: translateY(-100vh) translateX(40px); opacity: 0; }
}

/* Login Card */
.login-card {
  position: relative;
  z-index: 2;
  width: 420px;
  max-width: 92vw;
  padding: 48px 40px;
  background: rgba(17, 24, 39, 0.85);
  backdrop-filter: blur(30px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow:
    0 0 0 1px rgba(201, 164, 78, 0.08),
    0 20px 60px rgba(0, 0, 0, 0.5),
    0 0 80px rgba(201, 164, 78, 0.05);
  animation: loginCardIn 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes loginCardIn {
  from { opacity: 0; transform: translateY(30px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.login-card.shake {
  animation: shakeCard 0.5s ease;
}

@keyframes shakeCard {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-8px); }
  20%, 40%, 60%, 80% { transform: translateX(8px); }
}

/* Login Logo */
.login-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 28px;
}

.login-logo-icon {
  width: 48px;
  height: 48px;
  background: var(--gold-gradient);
  color: var(--bg-primary);
  font-weight: 800;
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(201, 164, 78, 0.3);
}

.login-logo-text {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 5px;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.login-logo-sub {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 3px;
  color: var(--text-muted);
  text-transform: uppercase;
}

.login-title {
  text-align: center;
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.login-subtitle {
  text-align: center;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 32px;
}

/* Login Form */
.login-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.login-field label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.login-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.login-input-icon {
  position: absolute;
  left: 14px;
  color: var(--text-muted);
  pointer-events: none;
  transition: color 0.2s;
}

.login-input-wrap:focus-within .login-input-icon {
  color: var(--gold-primary);
}

.login-input-wrap input {
  width: 100%;
  padding: 13px 16px 13px 46px;
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: all 0.25s;
}

.login-input-wrap input:focus {
  border-color: var(--gold-primary);
  box-shadow: 0 0 0 3px rgba(201, 164, 78, 0.12);
}

.login-input-wrap input::placeholder {
  color: var(--text-muted);
}

/* Eye Button */
.login-eye-btn {
  position: absolute;
  right: 12px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: color 0.2s;
  display: flex;
  align-items: center;
}

.login-eye-btn:hover {
  color: var(--gold-primary);
}

/* Login Options */
.login-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.login-remember {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  user-select: none;
}

.login-remember input {
  display: none;
}

.login-checkbox {
  width: 18px;
  height: 18px;
  border: 2px solid var(--border-light);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  flex-shrink: 0;
}

.login-remember input:checked + .login-checkbox {
  background: var(--gold-primary);
  border-color: var(--gold-primary);
}

.login-remember input:checked + .login-checkbox::after {
  content: '✓';
  color: var(--bg-primary);
  font-size: 11px;
  font-weight: 700;
}

/* Login Button */
.login-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 24px;
  background: var(--gold-gradient);
  color: var(--bg-primary);
  border: none;
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.3s;
  margin-top: 4px;
}

.login-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(201, 164, 78, 0.35);
}

.login-btn:active {
  transform: translateY(0);
}

.login-btn.success {
  background: linear-gradient(135deg, var(--green), #34d399);
  pointer-events: none;
}

/* Login Error */
.login-error {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: var(--radius-sm);
  color: var(--red);
  font-size: 13px;
  font-weight: 500;
  animation: fadeIn 0.3s ease;
}

.login-error.show {
  display: flex;
}

/* Login Footer */
.login-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 28px;
  font-size: 12px;
  color: var(--text-muted);
}

.login-footer a {
  color: var(--gold-primary);
  text-decoration: none;
  transition: opacity 0.2s;
}

.login-footer a:hover {
  opacity: 0.8;
}

/* ===== Reset ===== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  display: flex;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}
::-webkit-scrollbar-thumb {
  background: var(--gold-dark);
  border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--gold-primary);
}

/* ===== Sidebar ===== */
.sidebar {
  width: var(--sidebar-width);
  min-height: 100vh;
  background: var(--bg-sidebar);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  z-index: 100;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar-header {
  padding: 20px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-color);
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-primary);
}

.logo-icon {
  width: 38px;
  height: 38px;
  background: var(--gold-gradient);
  color: var(--bg-primary);
  font-weight: 800;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  letter-spacing: -1px;
}

.logo-text {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 3px;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.sidebar-toggle {
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
  transition: all 0.2s;
  display: none;
}

.sidebar-toggle:hover {
  color: var(--gold-primary);
  background: rgba(201, 164, 78, 0.1);
}

/* Sidebar Navigation */
.sidebar-nav {
  flex: 1;
  padding: 16px 12px;
  overflow-y: auto;
}

.nav-section {
  margin-bottom: 24px;
}

.nav-label {
  display: block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
  padding: 0 14px;
  margin-bottom: 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.25s ease;
  position: relative;
  margin-bottom: 2px;
}

.nav-item:hover {
  background: rgba(201, 164, 78, 0.08);
  color: var(--text-primary);
}

.nav-item.active {
  background: rgba(201, 164, 78, 0.12);
  color: var(--gold-primary);
}

.nav-item.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 20px;
  background: var(--gold-gradient);
  border-radius: 0 4px 4px 0;
}

.nav-icon {
  font-size: 18px;
  width: 24px;
  text-align: center;
  flex-shrink: 0;
}

.nav-text {
  white-space: nowrap;
}

/* Sidebar Footer */
.sidebar-footer {
  padding: 16px;
  border-top: 1px solid var(--border-color);
}

.user-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: rgba(201, 164, 78, 0.06);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
}

.user-avatar {
  width: 36px;
  height: 36px;
  background: var(--gold-gradient);
  color: var(--bg-primary);
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  flex-shrink: 0;
}

.user-info {
  display: flex;
  flex-direction: column;
}

.user-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.user-role {
  font-size: 11px;
  color: var(--text-muted);
}

/* ===== Main Content ===== */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  transition: margin-left 0.3s ease;
}

/* ===== Top Bar ===== */
.top-bar {
  height: var(--topbar-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(20px);
}

.top-bar-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
}

.page-title {
  font-size: 20px;
  font-weight: 700;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.top-bar-right {
  display: flex;
  align-items: center;
  gap: 14px;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--bg-input);
  border-radius: 30px;
  border: 1px solid var(--border-light);
  transition: border-color 0.3s;
}

.search-box:focus-within {
  border-color: var(--gold-primary);
}

.search-box svg {
  color: var(--text-muted);
  flex-shrink: 0;
}

.search-box input {
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 13px;
  width: 180px;
  outline: none;
  font-family: inherit;
}

.search-box input::placeholder {
  color: var(--text-muted);
}

.notification-btn {
  position: relative;
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  color: var(--text-secondary);
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}

.notification-btn:hover {
  border-color: var(--gold-primary);
  color: var(--gold-primary);
}

.notification-dot {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 7px;
  height: 7px;
  background: var(--red);
  border-radius: 50%;
  border: 2px solid var(--bg-secondary);
}

.top-bar-avatar .avatar-circle {
  width: 38px;
  height: 38px;
  background: var(--gold-gradient);
  color: var(--bg-primary);
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  cursor: pointer;
}

/* ===== Pages ===== */
.page {
  display: none;
  padding: 28px;
  animation: fadeIn 0.4s ease;
}

.page.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Page Header */
.page-header-bar {
  margin-bottom: 28px;
}

.page-header-bar h2 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 6px;
}

.page-header-bar p {
  color: var(--text-secondary);
  font-size: 14px;
}

/* ===== Stats Overview ===== */
.stats-overview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 22px;
  transition: all 0.3s ease;
  animation: slideUp 0.5s ease forwards;
  opacity: 0;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.stat-card:hover {
  border-color: var(--gold-primary);
  box-shadow: var(--shadow-gold);
  transform: translateY(-2px);
}

.stat-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.stat-card-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.stat-card-icon.revenue { background: rgba(201, 164, 78, 0.15); }
.stat-card-icon.projects { background: rgba(59, 130, 246, 0.15); }
.stat-card-icon.clients { background: rgba(16, 185, 129, 0.15); }
.stat-card-icon.instagram { background: rgba(139, 92, 246, 0.15); }
.stat-card-icon.pending { background: rgba(245, 158, 11, 0.15); }

.stat-card-trend {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 20px;
}

.stat-card-trend.up {
  color: var(--green);
  background: rgba(16, 185, 129, 0.1);
}

.stat-card-trend.neutral {
  color: var(--orange);
  background: rgba(245, 158, 11, 0.1);
}

.stat-card-value {
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 4px;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-card-label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.stat-card-bar {
  height: 4px;
  background: var(--bg-input);
  border-radius: 10px;
  overflow: hidden;
}

.stat-card-bar-fill {
  height: 100%;
  background: var(--gold-gradient);
  border-radius: 10px;
  transition: width 1.5s ease;
}

/* ===== Dashboard Grid ===== */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 20px;
}

.dashboard-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 22px;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.card-header h3 {
  font-size: 16px;
  font-weight: 600;
}

.card-actions {
  display: flex;
  gap: 6px;
}

.chip {
  padding: 5px 14px;
  border-radius: 20px;
  border: 1px solid var(--border-light);
  background: transparent;
  color: var(--text-secondary);
  font-size: 12px;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
}

.chip.active {
  background: rgba(201, 164, 78, 0.15);
  color: var(--gold-primary);
  border-color: rgba(201, 164, 78, 0.3);
}

.chip:hover {
  border-color: var(--gold-primary);
}

.view-all {
  color: var(--gold-primary);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: opacity 0.2s;
}

.view-all:hover {
  opacity: 0.8;
}

/* Chart */
.chart-container {
  height: 280px;
}

.chart-container canvas {
  width: 100%;
  height: 100%;
}

/* Activity List */
.activity-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.activity-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius-sm);
  transition: background 0.2s;
}

.activity-item:hover {
  background: rgba(255, 255, 255, 0.03);
}

.activity-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
}

.activity-icon.green { background: rgba(16, 185, 129, 0.15); }
.activity-icon.blue { background: rgba(59, 130, 246, 0.15); }
.activity-icon.gold { background: rgba(201, 164, 78, 0.15); }
.activity-icon.purple { background: rgba(139, 92, 246, 0.15); }
.activity-icon.red { background: rgba(239, 68, 68, 0.15); }

.activity-text {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.activity-text strong {
  color: var(--text-primary);
}

.activity-time {
  font-size: 11px;
  color: var(--text-muted);
}

/* Country Performance */
.country-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.country-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.country-flag-small {
  font-size: 18px;
  flex-shrink: 0;
}

.country-name {
  font-size: 13px;
  color: var(--text-secondary);
  width: 100px;
  flex-shrink: 0;
}

.country-bar-wrap {
  flex: 1;
  height: 6px;
  background: var(--bg-input);
  border-radius: 10px;
  overflow: hidden;
}

.country-bar {
  height: 100%;
  background: var(--gold-gradient);
  border-radius: 10px;
  transition: width 1.5s ease;
}

.country-percent {
  font-size: 12px;
  font-weight: 600;
  color: var(--gold-primary);
  width: 36px;
  text-align: right;
}

/* ===== Contact Page ===== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.contact-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 24px;
}

.contact-card.full-width {
  grid-column: 1 / -1;
}

.contact-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-light);
}

.contact-card-icon {
  font-size: 22px;
}

.contact-card-header h3 {
  font-size: 16px;
  font-weight: 600;
}

/* Forms */
.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 11px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 14px;
  font-family: inherit;
  transition: all 0.25s;
  outline: none;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--gold-primary);
  box-shadow: 0 0 0 3px rgba(201, 164, 78, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.form-group select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%238b95a8' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.input-with-icon {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 14px;
  font-size: 16px;
  pointer-events: none;
}

.input-with-icon input {
  padding-left: 44px;
}

.btn-save {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 24px;
  background: var(--gold-gradient);
  color: var(--bg-primary);
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.3s;
}

.btn-save:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-gold);
}

.btn-save:active {
  transform: translateY(0);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-outline:hover {
  border-color: var(--gold-primary);
  color: var(--gold-primary);
}

.btn-outline.danger:hover {
  border-color: var(--red);
  color: var(--red);
}

/* ===== Settings Page ===== */
.settings-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.settings-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  overflow: hidden;
}

.settings-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-light);
}

.settings-icon {
  font-size: 20px;
}

.settings-card-header h3 {
  font-size: 16px;
  font-weight: 600;
}

.settings-body {
  padding: 24px;
}

/* Profile Avatar */
.profile-avatar-section {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-light);
}

.profile-avatar-large {
  width: 64px;
  height: 64px;
  background: var(--gold-gradient);
  color: var(--bg-primary);
  font-weight: 800;
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  flex-shrink: 0;
}

.profile-avatar-actions {
  display: flex;
  gap: 8px;
}

/* Toggle Switches */
.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--border-light);
}

.toggle-row:last-of-type {
  border-bottom: none;
}

.toggle-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.toggle-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

.toggle-desc {
  font-size: 12px;
  color: var(--text-muted);
}

.toggle-switch {
  position: relative;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--bg-input);
  border-radius: 24px;
  cursor: pointer;
  transition: all 0.3s;
  border: 1px solid var(--border-light);
}

.toggle-slider::before {
  content: '';
  position: absolute;
  left: 3px;
  top: 3px;
  width: 16px;
  height: 16px;
  background: var(--text-muted);
  border-radius: 50%;
  transition: all 0.3s;
}

.toggle-switch input:checked + .toggle-slider {
  background: rgba(201, 164, 78, 0.2);
  border-color: var(--gold-primary);
}

.toggle-switch input:checked + .toggle-slider::before {
  transform: translateX(20px);
  background: var(--gold-primary);
}

/* Color Options */
.color-options {
  display: flex;
  gap: 10px;
  margin-top: 6px;
}

.color-swatch {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
}

.color-swatch:hover {
  transform: scale(1.1);
}

.color-swatch.active {
  border-color: white;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.15);
}

.color-swatch.active::after {
  content: '✓';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 14px;
  font-weight: 700;
  text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

/* ===== Instagram Posts Grid ===== */
.ig-stats-bar {
  display: flex;
  gap: 20px;
  margin-bottom: 24px;
  padding: 18px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
}

.ig-stat {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ig-stat-number {
  font-size: 20px;
  font-weight: 700;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.ig-stat-label {
  font-size: 12px;
  color: var(--text-muted);
}

.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

.post-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all 0.3s ease;
}

.post-card:hover {
  border-color: var(--gold-primary);
  transform: translateY(-3px);
  box-shadow: var(--shadow-gold);
}

.post-image {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
}

.post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.post-card:hover .post-image img {
  transform: scale(1.05);
}

.post-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s;
}

.post-card:hover .post-overlay {
  opacity: 1;
}

.post-overlay-stats {
  display: flex;
  gap: 20px;
  font-size: 16px;
  font-weight: 600;
  color: white;
}

.post-info {
  padding: 18px;
}

.post-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
}

.post-location {
  font-size: 12px;
  font-weight: 600;
  color: var(--gold-primary);
}

.post-date {
  font-size: 12px;
  color: var(--text-muted);
}

.post-caption {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 14px;
}

.post-actions {
  display: flex;
  gap: 6px;
}

.btn-post-action {
  padding: 6px 12px;
  border: 1px solid var(--border-light);
  background: transparent;
  color: var(--text-secondary);
  border-radius: 6px;
  font-size: 12px;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-post-action:hover {
  border-color: var(--gold-primary);
  color: var(--gold-primary);
}

.btn-post-action.edit:hover {
  border-color: var(--blue);
  color: var(--blue);
  background: rgba(59, 130, 246, 0.08);
}

.btn-post-action.download:hover {
  border-color: var(--green);
  color: var(--green);
  background: rgba(16, 185, 129, 0.08);
}

.btn-post-action.schedule:hover {
  border-color: var(--purple);
  color: var(--purple);
  background: rgba(139, 92, 246, 0.08);
}

/* ===== Instagram Stories Grid ===== */
.stories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
}

.story-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all 0.3s ease;
}

.story-card:hover {
  border-color: var(--gold-primary);
  transform: translateY(-3px);
  box-shadow: var(--shadow-gold);
}

.story-image {
  position: relative;
  aspect-ratio: 9/16;
  overflow: hidden;
}

.story-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.story-card:hover .story-image img {
  transform: scale(1.05);
}

.story-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  opacity: 0;
  transition: opacity 0.3s;
}

.story-card:hover .story-overlay {
  opacity: 1;
}

.story-overlay-stats {
  display: flex;
  gap: 16px;
  font-size: 14px;
  font-weight: 600;
  color: white;
}

.story-view-btn {
  padding: 8px 24px;
  background: var(--gold-gradient);
  color: var(--bg-primary);
  border: none;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
}

.story-view-btn:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-gold);
}

.story-info {
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.story-location {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.story-status {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
}

.story-status.active {
  color: var(--green);
  background: rgba(16, 185, 129, 0.1);
}

.story-status.scheduled {
  color: var(--blue);
  background: rgba(59, 130, 246, 0.1);
}

.story-status.draft {
  color: var(--text-muted);
  background: rgba(74, 85, 104, 0.15);
}

/* ===== Payments Table ===== */
.payments-table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  overflow: hidden;
}

.table-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-light);
}

.table-header-bar h3 {
  font-size: 16px;
  font-weight: 600;
}

.payments-table {
  width: 100%;
  border-collapse: collapse;
}

.payments-table th {
  text-align: left;
  padding: 14px 20px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-light);
}

.payments-table td {
  padding: 16px 20px;
  font-size: 14px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-light);
}

.payments-table tbody tr {
  transition: background 0.2s;
}

.payments-table tbody tr:hover {
  background: rgba(201, 164, 78, 0.04);
}

.payments-table tbody tr:last-child td {
  border-bottom: none;
}

.invoice-id {
  font-weight: 600;
  color: var(--gold-primary) !important;
  font-family: 'Courier New', monospace;
}

.amount {
  font-weight: 700;
  color: var(--text-primary) !important;
}

.status-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.status-badge.paid {
  color: var(--green);
  background: rgba(16, 185, 129, 0.1);
}

.status-badge.pending {
  color: var(--orange);
  background: rgba(245, 158, 11, 0.1);
}

.status-badge.overdue {
  color: var(--red);
  background: rgba(239, 68, 68, 0.1);
}

.btn-table {
  background: transparent;
  border: 1px solid var(--border-light);
  color: var(--text-secondary);
  width: 32px;
  height: 32px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.btn-table:hover {
  border-color: var(--gold-primary);
  background: rgba(201, 164, 78, 0.1);
}

/* ===== Lightbox ===== */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(20px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}

.lightbox-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.lightbox-content {
  position: relative;
  max-width: 400px;
  max-height: 90vh;
}

.lightbox-content img {
  width: 100%;
  height: auto;
  max-height: 90vh;
  object-fit: contain;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: none;
  border: none;
  color: white;
  font-size: 32px;
  cursor: pointer;
  transition: color 0.2s;
}

.lightbox-close:hover {
  color: var(--gold-primary);
}

/* ===== Toast ===== */
.toast {
  position: fixed;
  bottom: 30px;
  right: 30px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  background: var(--bg-card);
  border: 1px solid var(--green);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 500;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.toast-icon {
  width: 24px;
  height: 24px;
  background: rgba(16, 185, 129, 0.15);
  color: var(--green);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
}

.toast-message {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .settings-grid {
    grid-template-columns: 1fr;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .ig-stats-bar {
    flex-wrap: wrap;
  }
}

@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.mobile-open {
    transform: translateX(0);
    box-shadow: var(--shadow-lg);
  }

  .main-content {
    margin-left: 0;
  }

  .mobile-toggle {
    display: flex;
  }

  .page {
    padding: 20px 16px;
  }

  .top-bar {
    padding: 0 16px;
  }

  .search-box {
    display: none;
  }

  .page-title {
    font-size: 16px;
  }

  .stats-overview {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .stat-card {
    padding: 16px;
  }

  .stat-card-value {
    font-size: 22px;
  }

  .posts-grid {
    grid-template-columns: 1fr;
  }

  .stories-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .payments-table {
    font-size: 12px;
  }

  .payments-table th,
  .payments-table td {
    padding: 10px 12px;
  }

  .ig-stats-bar {
    padding: 14px;
    gap: 12px;
  }

  .post-overlay-stats {
    font-size: 14px;
    gap: 14px;
  }
}

@media (max-width: 480px) {
  .stats-overview {
    grid-template-columns: 1fr;
  }

  .stories-grid {
    grid-template-columns: 1fr;
    max-width: 320px;
  }

  .top-bar-right {
    gap: 8px;
  }
}

/* ===== Animations ===== */
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.notification-dot {
  animation: pulse 2s infinite;
}

/* Hover glow effect on cards */
.stat-card::before,
.post-card::before,
.story-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--gold-gradient);
  opacity: 0;
  transition: opacity 0.3s;
}

.stat-card:hover::before,
.post-card:hover::before,
.story-card:hover::before {
  opacity: 1;
}

.stat-card,
.post-card,
.story-card {
  position: relative;
}

/* ===== Wayl Payment Gateway Styles ===== */

/* Wayl Badge */
.wayl-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 12px;
  border-radius: 20px;
  background: linear-gradient(135deg, #102326, #1a3a3f);
  color: #4dd0e1;
  border: 1px solid rgba(77, 208, 225, 0.3);
  vertical-align: middle;
  margin-left: 10px;
}

.wayl-link {
  color: #4dd0e1;
  text-decoration: none;
  transition: color 0.2s;
}

.wayl-link:hover {
  color: #80deea;
  text-decoration: underline;
}

/* Wayl Connection Bar */
.wayl-connection-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: linear-gradient(135deg, #0d1f23, #102326);
  border: 1px solid rgba(77, 208, 225, 0.2);
  border-radius: var(--radius);
  margin-bottom: 24px;
  gap: 20px;
  flex-wrap: wrap;
}

.wayl-connection-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.wayl-logo-wrap {
  color: #4dd0e1;
  flex-shrink: 0;
}

.wayl-connection-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.wayl-connection-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.wayl-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.wayl-status-dot.connected {
  background: var(--green);
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);
  animation: pulse 2s infinite;
}

.wayl-status-dot.disconnected {
  background: var(--red);
  box-shadow: 0 0 8px rgba(239, 68, 68, 0.5);
}

.wayl-connection-detail {
  font-size: 12px;
  color: var(--text-muted);
}

.wayl-connection-right {
  display: flex;
  align-items: center;
}

/* Payment Method Badges */
.wayl-methods {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.wayl-method-badge {
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.3px;
}

.wayl-method-badge.visa {
  background: rgba(26, 35, 126, 0.3);
  color: #5c6bc0;
  border: 1px solid rgba(92, 107, 192, 0.3);
}

.wayl-method-badge.mc {
  background: rgba(230, 81, 0, 0.2);
  color: #ff9800;
  border: 1px solid rgba(255, 152, 0, 0.3);
}

.wayl-method-badge.zc {
  background: rgba(0, 137, 123, 0.2);
  color: #4db6ac;
  border: 1px solid rgba(77, 182, 172, 0.3);
}

.wayl-method-badge.fib {
  background: rgba(183, 28, 28, 0.2);
  color: #ef5350;
  border: 1px solid rgba(239, 83, 80, 0.3);
}

.wayl-method-badge.fp {
  background: rgba(74, 20, 140, 0.2);
  color: #ce93d8;
  border: 1px solid rgba(206, 147, 216, 0.3);
}

/* Wayl Panel Grid */
.wayl-panel-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

.wayl-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  overflow: hidden;
}

.wayl-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-light);
}

.wayl-card-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.wayl-card-icon {
  font-size: 18px;
}

.wayl-card-header h3 {
  font-size: 15px;
  font-weight: 600;
}

.wayl-card-tag {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 3px 10px;
  border-radius: 4px;
  background: rgba(77, 208, 225, 0.1);
  color: #4dd0e1;
  border: 1px solid rgba(77, 208, 225, 0.2);
}

.wayl-card-body {
  padding: 24px;
}

/* Wayl Create Button */
.btn-wayl-create {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 28px;
  background: linear-gradient(135deg, #102326, #1a4a50);
  color: #4dd0e1;
  border: 1px solid rgba(77, 208, 225, 0.3);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.3s;
  width: 100%;
  justify-content: center;
}

.btn-wayl-create:hover {
  background: linear-gradient(135deg, #143034, #1e5a62);
  border-color: rgba(77, 208, 225, 0.5);
  box-shadow: 0 4px 20px rgba(77, 208, 225, 0.15);
  transform: translateY(-1px);
}

.btn-wayl-create:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Wayl Verify Button */
.btn-wayl-verify {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: transparent;
  color: var(--green);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
  margin-bottom: 20px;
}

.btn-wayl-verify:hover {
  background: rgba(16, 185, 129, 0.1);
  border-color: var(--green);
}

/* Wayl Endpoint Display */
.wayl-endpoint-display {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-family: 'Courier New', monospace;
  font-size: 13px;
  color: var(--text-secondary);
}

.endpoint-method {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 4px;
  background: rgba(16, 185, 129, 0.15);
  color: var(--green);
  font-family: inherit;
}

.endpoint-header {
  font-size: 12px;
  color: #4dd0e1;
  font-weight: 600;
}

/* Wayl API Info */
.wayl-api-info {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-top: 16px;
  border-top: 1px solid var(--border-light);
}

.wayl-info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
}

.wayl-info-label {
  color: var(--text-muted);
}

.wayl-info-value {
  color: var(--text-secondary);
  font-weight: 500;
}

/* Form Hint */
.form-hint {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}

.form-hint a {
  color: #4dd0e1;
}

/* Wayl Result */
.wayl-result {
  padding: 20px 24px;
  border-top: 1px solid rgba(16, 185, 129, 0.2);
  background: rgba(16, 185, 129, 0.04);
  animation: fadeIn 0.4s ease;
}

.wayl-result-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--green);
}

.wayl-result-link {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.wayl-result-link input {
  flex: 1;
  padding: 10px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  color: #4dd0e1;
  font-size: 13px;
  font-family: 'Courier New', monospace;
  outline: none;
}

.btn-copy-link {
  padding: 10px 16px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: var(--green);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-copy-link:hover {
  background: rgba(16, 185, 129, 0.2);
}

.wayl-result-actions {
  display: flex;
  gap: 8px;
}

/* Send via Wayl button (in table) */
.btn-wayl-send {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: linear-gradient(135deg, #102326, #1a4a50);
  color: #4dd0e1;
  border: 1px solid rgba(77, 208, 225, 0.3);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-wayl-send:hover {
  background: linear-gradient(135deg, #143034, #1e5a62);
  border-color: rgba(77, 208, 225, 0.5);
  box-shadow: 0 2px 10px rgba(77, 208, 225, 0.15);
}

.btn-wayl-send:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-wayl-send.sent {
  background: rgba(16, 185, 129, 0.1);
  color: var(--green);
  border-color: rgba(16, 185, 129, 0.3);
}

/* Responsive: Wayl */
@media (max-width: 1024px) {
  .wayl-panel-grid {
    grid-template-columns: 1fr;
  }

  .wayl-connection-bar {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 768px) {
  .wayl-methods {
    gap: 4px;
  }

  .wayl-method-badge {
    font-size: 10px;
    padding: 3px 8px;
  }

  .wayl-result-link {
    flex-direction: column;
  }

  .wayl-result-actions {
    flex-direction: column;
  }
}

/* ===== Contracts System ===== */

.contract-panel-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

.contract-create-card,
.contract-preview-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  overflow: hidden;
}

/* Contract Preview */
.contract-preview-body {
  padding: 24px;
  max-height: 500px;
  overflow-y: auto;
}

.contract-preview-actions {
  padding: 16px 24px;
  border-top: 1px solid var(--border-light);
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* Contract Document */
.contract-doc {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 24px;
  font-size: 13px;
}

.contract-doc-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--gold-primary);
}

.contract-doc-logo {
  width: 40px;
  height: 40px;
  background: var(--gold-gradient);
  color: var(--bg-primary);
  font-weight: 800;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  flex-shrink: 0;
}

.contract-doc-header h3 {
  font-size: 16px;
  letter-spacing: 3px;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.contract-doc-header p {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.contract-doc-id {
  margin-left: auto;
  font-family: 'Courier New', monospace;
  font-size: 12px;
  color: var(--gold-primary);
  font-weight: 600;
}

.contract-doc-parties {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 20px;
}

.contract-party {
  padding: 14px;
  background: var(--bg-input);
  border-radius: var(--radius-sm);
  font-size: 12px;
  line-height: 1.7;
  color: var(--text-secondary);
}

.contract-party strong {
  color: var(--text-primary);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.contract-doc-section {
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-light);
}

.contract-doc-section h4 {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gold-primary);
  margin-bottom: 6px;
}

.contract-doc-section p {
  color: var(--text-secondary);
  line-height: 1.7;
  font-size: 12px;
}

.contract-doc-signatures {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin: 24px 0 16px;
}

.contract-sig-block {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.contract-sig-block span {
  font-size: 11px;
  color: var(--text-muted);
}

.contract-sig-block small {
  font-size: 10px;
  color: var(--green);
}

.contract-sig-line {
  min-height: 50px;
  border-bottom: 2px solid var(--text-muted);
  padding: 8px 0;
  font-size: 12px;
  color: var(--text-muted);
  font-style: italic;
  display: flex;
  align-items: flex-end;
}

.contract-sig-line.signed {
  border-bottom-color: var(--gold-primary);
}

.contract-sig-line img {
  height: 50px;
  max-width: 100%;
  object-fit: contain;
}

.contract-doc-footer {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--text-muted);
}

/* Contract List */
.contracts-list {
  padding: 0;
}

.contracts-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  gap: 12px;
  color: var(--text-muted);
}

.contracts-empty-icon {
  font-size: 48px;
  opacity: 0.3;
}

.contracts-empty p {
  font-size: 14px;
}

.contract-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-light);
  transition: background 0.2s;
  gap: 16px;
}

.contract-item:hover {
  background: rgba(201, 164, 78, 0.04);
}

.contract-item:last-child {
  border-bottom: none;
}

.contract-item-info {
  flex: 1;
}

.contract-item-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}

.contract-item-id {
  font-family: 'Courier New', monospace;
  font-size: 12px;
  font-weight: 600;
  color: var(--gold-primary);
}

.contract-item-info h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.contract-item-info p {
  font-size: 12px;
  color: var(--text-muted);
}

.signed-date {
  font-size: 11px !important;
  color: var(--green) !important;
  display: block;
  margin-top: 2px;
}

.contract-item-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

/* Contract Modal */
.contract-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}

.contract-modal-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.contract-modal {
  width: 700px;
  max-width: 95vw;
  max-height: 90vh;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: loginCardIn 0.4s ease;
}

.contract-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 28px;
  border-bottom: 1px solid var(--border-light);
  position: sticky;
  top: 0;
  background: var(--bg-card);
  z-index: 10;
}

.contract-modal-header h2 {
  font-size: 18px;
  font-weight: 700;
}

.contract-modal-close {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 28px;
  cursor: pointer;
  transition: color 0.2s;
  line-height: 1;
}

.contract-modal-close:hover {
  color: var(--gold-primary);
}

.contract-modal-body {
  padding: 28px;
}

.contract-modal-sign {
  padding: 24px 28px;
  border-top: 1px solid var(--border-light);
  background: rgba(201, 164, 78, 0.03);
}

.contract-modal-sign h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 4px;
}

.contract-modal-sign p {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.contract-modal-sign canvas {
  display: block;
  border-radius: var(--radius-sm);
  cursor: crosshair;
  margin-bottom: 14px;
  max-width: 100%;
  touch-action: none;
}

.signature-actions {
  display: flex;
  gap: 10px;
}

.contract-modal-signed {
  padding: 40px 28px;
}

.signed-success {
  text-align: center;
}

.signed-icon {
  font-size: 48px;
  display: block;
  margin-bottom: 12px;
}

.signed-success h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--green);
  margin-bottom: 8px;
}

.signed-success p {
  color: var(--text-secondary);
  font-size: 14px;
}

/* Responsive: Contracts */
@media (max-width: 1024px) {
  .contract-panel-grid {
    grid-template-columns: 1fr;
  }
  .contract-doc-parties {
    grid-template-columns: 1fr;
  }
  .contract-doc-signatures {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .contract-item {
    flex-direction: column;
    align-items: flex-start;
  }
  .contract-item-actions {
    width: 100%;
  }
  .contract-modal {
    max-height: 95vh;
    border-radius: var(--radius);
  }
  .signature-actions {
    flex-direction: column;
  }
}

/* Admin Signature Section */
.contract-admin-sign {
  padding: 20px 24px;
  border-top: 1px solid var(--border-light);
  background: rgba(201, 164, 78, 0.04);
}

.contract-admin-sign h4 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--gold-primary);
}

.contract-admin-sign p {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.contract-admin-sign canvas {
  display: block;
  border-radius: var(--radius-sm);
  cursor: crosshair;
  margin-bottom: 12px;
  max-width: 100%;
  touch-action: none;
}

/* ===== Contract Signing Link Box ===== */
.contract-signing-link-box {
  margin-top: 20px;
  padding: 20px;
  background: rgba(201, 164, 78, 0.06);
  border: 1px solid rgba(201, 164, 78, 0.2);
  border-radius: var(--radius);
}

.signing-link-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--gold-primary);
  margin-bottom: 12px;
}

.signing-link-display {
  display: flex;
  gap: 8px;
}

.signing-link-display input {
  flex: 1;
  padding: 10px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 13px;
  font-family: monospace;
}

/* ===== Contract Signatures Preview (in list) ===== */
.contract-signatures-preview {
  display: flex;
  gap: 16px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border-light);
}

.sig-thumb {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.sig-thumb small {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.sig-thumb img {
  max-height: 35px;
  max-width: 100px;
  object-fit: contain;
  border-radius: 4px;
  border: 1px solid rgba(201, 164, 78, 0.2);
  padding: 2px;
  background: rgba(13, 19, 33, 0.5);
}

/* ===== Contract Item Improvements ===== */
.contract-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-light);
  transition: background 0.2s;
}

.contract-item:hover {
  background: rgba(201, 164, 78, 0.03);
}

.contract-item:last-child {
  border-bottom: none;
}

.contract-item-info {
  flex: 1;
}

.contract-item-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.contract-item-id {
  font-family: monospace;
  font-size: 12px;
  color: var(--text-muted);
  background: var(--bg-input);
  padding: 3px 8px;
  border-radius: 4px;
}

.contract-item-info h4 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.contract-item-info > p {
  font-size: 13px;
  color: var(--text-secondary);
}

.contract-item-info .signed-date {
  display: block;
  margin-top: 6px;
  font-size: 12px;
  color: var(--green);
}

.contract-item-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-shrink: 0;
}

/* ===== Contracts Empty State ===== */
.contracts-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
  text-align: center;
}

.contracts-empty-icon {
  font-size: 48px;
  margin-bottom: 12px;
}

.contracts-empty p {
  color: var(--text-muted);
  font-size: 14px;
}
