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

/* Design System CSS Custom Properties */
:root {
  --font-heading: 'Outfit', 'Inter', sans-serif;
  --font-body: 'Inter', sans-serif;

  /* Premium Color Palette (Dark Theme / Glassmorphism) */
  --bg-gradient-start: #0a0b10;
  --bg-gradient-end: #12131a;
  
  --color-primary: #6366f1; /* Neon Indigo */
  --color-primary-glow: rgba(99, 102, 241, 0.4);
  --color-secondary: #a855f7; /* Violet */
  --color-secondary-glow: rgba(168, 85, 247, 0.4);
  
  --color-success: #10b981; /* Emerald Green */
  --color-success-glow: rgba(16, 185, 129, 0.3);
  --color-error: #ef4444; /* Rose Red */
  --color-error-glow: rgba(239, 68, 68, 0.3);

  --glass-bg: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.07);
  --glass-border-hover: rgba(255, 255, 255, 0.15);
  --glass-shadow: rgba(0, 0, 0, 0.4);
  
  --text-main: #f3f4f6;
  --text-muted: #9ca3af;
  --text-light: #ffffff;
  
  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --radius-lg: 16px;
  --radius-md: 10px;
}

/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-body);
  background: linear-gradient(135deg, var(--bg-gradient-start), var(--bg-gradient-end));
  background-attachment: fixed;
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow-x: hidden;
  position: relative;
}

/* Glowing Background Accents */
body::before {
  content: '';
  position: absolute;
  top: 15%;
  left: 20%;
  width: 300px;
  height: 300px;
  background: var(--color-primary);
  border-radius: 50%;
  filter: blur(140px);
  opacity: 0.15;
  z-index: 0;
  pointer-events: none;
}

body::after {
  content: '';
  position: absolute;
  bottom: 15%;
  right: 20%;
  width: 350px;
  height: 350px;
  background: var(--color-secondary);
  border-radius: 50%;
  filter: blur(160px);
  opacity: 0.15;
  z-index: 0;
  pointer-events: none;
}

/* Navigation Bar (Glassmorphic) */
.nav-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 70px;
  background: rgba(10, 11, 16, 0.6);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-bottom: 1px solid var(--glass-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 40px;
  z-index: 100;
}

.nav-brand {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  background: linear-gradient(to right, var(--color-primary), var(--color-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-links {
  display: flex;
  gap: 20px;
}

.nav-btn {
  text-decoration: none;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.9rem;
  padding: 8px 16px;
  border-radius: var(--radius-md);
  transition: var(--transition-smooth);
  border: 1px solid transparent;
}

.nav-btn:hover, .nav-btn.active {
  color: var(--text-light);
  background: var(--glass-bg);
  border-color: var(--glass-border);
}

/* Premium Layout Container */
.container {
  width: 100%;
  max-width: 1100px;
  margin-top: 100px;
  margin-bottom: 60px;
  padding: 0 20px;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Glassmorphic Cards */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 32px var(--glass-shadow);
  padding: 40px;
  width: 100%;
  max-width: 550px;
  transition: var(--transition-smooth);
}

.glass-card:hover {
  border-color: var(--glass-border-hover);
}

.glass-card.wide {
  max-width: 1000px;
}

.glass-card.checkout-active {
  max-width: 850px;
  padding: 20px;
}

/* Headings */
h1 {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 2.2rem;
  margin-bottom: 10px;
  background: linear-gradient(135deg, #fff 0%, #a5b4fc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-align: center;
}

.subtitle {
  color: var(--text-muted);
  text-align: center;
  font-size: 1rem;
  margin-bottom: 30px;
}

/* Form Styles */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

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

.form-input {
  width: 100%;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  color: var(--text-light);
  font-family: var(--font-body);
  font-size: 1rem;
  outline: none;
  transition: var(--transition-smooth);
}

.form-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 15px var(--color-primary-glow);
  background: rgba(0, 0, 0, 0.3);
}

.input-icon-left {
  padding-left: 45px;
}

.input-icon {
  position: absolute;
  left: 15px;
  color: var(--text-muted);
  font-size: 1.1rem;
  pointer-events: none;
}

/* Currency Input Special Decorator */
.currency-input-wrapper {
  position: relative;
}
.currency-symbol {
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  font-weight: 700;
  color: var(--color-primary);
  font-family: var(--font-heading);
}

/* Premium Buttons */
.btn-primary {
  width: 100%;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  border: none;
  color: var(--text-light);
  padding: 15px;
  border-radius: var(--radius-md);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1.05rem;
  cursor: pointer;
  transition: var(--transition-smooth);
  box-shadow: 0 4px 15px var(--color-primary-glow);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.6);
  opacity: 0.95;
}

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

.btn-primary:disabled {
  background: var(--text-muted);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Admin Dashboard Metrics Grid */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  width: 100%;
  margin-bottom: 30px;
}

.metric-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  transition: var(--transition-smooth);
}

.metric-card:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--glass-border-hover);
  transform: translateY(-2px);
}

.metric-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.metric-value {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-light);
}

.metric-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--color-primary);
}

.metric-card.success::after {
  background: var(--color-success);
}
.metric-card.accent::after {
  background: var(--color-secondary);
}

/* Premium Table Styles for Admin Dashboard */
.table-container {
  width: 100%;
  overflow-x: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--glass-border);
  background: rgba(0, 0, 0, 0.15);
}

.premium-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.premium-table th {
  background: rgba(255, 255, 255, 0.03);
  padding: 16px 20px;
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--text-light);
  border-bottom: 1px solid var(--glass-border);
}

.premium-table td {
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  color: var(--text-main);
}

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

.premium-table tr:hover td {
  background: rgba(255, 255, 255, 0.01);
  color: var(--text-light);
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.badge.success {
  background: rgba(16, 185, 129, 0.1);
  color: var(--color-success);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.badge.fail {
  background: rgba(239, 68, 68, 0.1);
  color: var(--color-error);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Status Result Screen (Callback page) */
.status-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 20px 0;
}

.status-icon-wrapper {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  font-size: 2.5rem;
  position: relative;
}

.status-icon-wrapper.success {
  background: rgba(16, 185, 129, 0.1);
  color: var(--color-success);
  border: 2px solid var(--color-success);
  box-shadow: 0 0 20px var(--color-success-glow);
}

.status-icon-wrapper.error {
  background: rgba(239, 68, 68, 0.1);
  color: var(--color-error);
  border: 2px solid var(--color-error);
  box-shadow: 0 0 20px var(--color-error-glow);
}

.status-title {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.status-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 30px;
  line-height: 1.6;
  max-width: 400px;
}

.status-details {
  width: 100%;
  background: rgba(0, 0, 0, 0.2);
  border-radius: var(--radius-md);
  padding: 20px;
  margin-bottom: 30px;
  text-align: left;
  border: 1px solid var(--glass-border);
}

.detail-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 12px;
  font-size: 0.9rem;
}

.detail-row:last-child {
  margin-bottom: 0;
}

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

.detail-value {
  color: var(--text-light);
  font-weight: 500;
}

/* Loading Spinner */
.spinner {
  border: 3px solid rgba(255, 255, 255, 0.1);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border-left-color: var(--text-light);
  animation: spin 1s linear infinite;
  display: inline-block;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Checkout Container (Where Iyzico mounts its iframe/form) */
#iyzico-checkout-container {
  width: 100%;
  margin-top: 20px;
  min-height: 200px;
  background: rgba(255, 255, 255, 0.01);
  border-radius: var(--radius-md);
  border: 1px dashed var(--glass-border);
  padding: 10px;
  display: none;
}

#iyzico-checkout-container.active {
  display: block;
  border-style: solid;
  background: #ffffff; /* Iyzico form matches white backgrounds best */
  padding: 25px;
  color: #333333;
}

/* Footers */
footer {
  margin-top: auto;
  padding: 30px 0;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  z-index: 10;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-gradient-start);
}

::-webkit-scrollbar-thumb {
  background: var(--glass-border);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--glass-border-hover);
}

/* Responsive tweaks */
@media (max-width: 768px) {
  .nav-bar {
    padding: 0 20px;
  }
  .glass-card {
    padding: 24px;
  }
  h1 {
    font-size: 1.8rem;
  }
  .metrics-grid {
    grid-template-columns: 1fr;
  }
}

/* Iyzico Iframe & Popup Modal Genişlik/Yükseklik Ayarları */
#iyzipay-checkout-form {
  width: 100% !important;
  max-width: 100% !important;
  min-height: 650px !important;
}

#iyzipay-checkout-form iframe {
  width: 100% !important;
  min-height: 650px !important;
  border: none !important;
}

/* Lightbox popup veya iframe olarak açılırsa modalı/iframe'i genişlet */
iframe,
.iyzico-responsive-modal,
.iyz-modal,
.iyzico-lightbox,
.iyz-lightbox,
#iyz-modal-wrapper,
.iyzico-responsive-modal-container {
  width: 540px !important;
  height: 720px !important;
  max-width: 95vw !important;
  max-height: 90vh !important;
  margin: auto !important;
  border-radius: 12px !important;
  border: none !important;
}

