/* ========================================
   PromptImageLab - Professional Theme
   Dark mode design system with Bootstrap integration
======================================== */

/* ========== CSS VARIABLES ========== */
:root {
  /* Background Colors */
  --bg: #020617;
  --surface: #071028;
  --surface-elevated: #0b1220;
  --border: rgba(255, 255, 255, .08);

  /* Text Colors */
  --text: #e6eef8;
  --muted: #9aa8bb;

  /* Accent Colors */
  --primary: #38bdf8;
  --secondary: #22c55e;
  --on-accent: #000000;

  /* Effects */
  --glass: rgba(255, 255, 255, .06);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, .3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, .4);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, .5);
}

/* ========== BASE STYLES ========== */
html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  font-family: Inter, system-ui, Segoe UI, Roboto, Helvetica, Arial, sans-serif !important;
  background: linear-gradient(180deg, var(--surface), var(--bg)) !important;
  color: var(--text) !important;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ========== LAYOUT ========== */
.container {
  max-width: 1200px;
  margin: auto;
  padding: 0 24px;
}

/* ========== NAVIGATION ========== */
nav.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(7, 16, 40, .85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.site-nav .nav-inner {
  height: 72px;
  display: flex;
  align-items: center;
  gap: 40px;
}

.site-nav .logo {
  font-weight: 800;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.site-nav .logo:hover {
  opacity: 0.8;
}

.site-nav .logo img {
  height: 32px;
  width: auto;
  border-radius: 6px;
}

.site-nav .nav-links {
  list-style: none;
  display: flex;
  gap: 24px;
  margin: 0;
  padding: 0;
}

.site-nav .nav-links a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s ease;
  font-weight: 500;
}

.site-nav .nav-links a:hover {
  color: var(--text);
}

/* ========== HERO SECTION ========== */
.hero {
  padding: 80px 0 60px;
}

.hero h1 {
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1.2;
  background: linear-gradient(135deg, var(--text), var(--primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 16px;
}

.hero p {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 720px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ========== TYPOGRAPHY ========== */
h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--text);
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 0.75rem;
}

h1 {
  font-size: 2.5rem;
}

h2 {
  font-size: 2rem;
}

h3 {
  font-size: 1.5rem;
}

h4 {
  font-size: 1.25rem;
}

h5 {
  font-size: 1.1rem;
}

h6 {
  font-size: 1rem;
}

p {
  margin-bottom: 1rem;
  line-height: 1.7;
}

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

/* ========== BOOTSTRAP CARDS (Dark Theme) ========== */
.card {
  background: linear-gradient(145deg,
      rgba(255, 255, 255, .05),
      rgba(255, 255, 255, .02)) !important;
  border: 1px solid var(--border) !important;
  border-radius: 16px !important;
  padding: 24px !important;
  color: var(--text) !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(56, 189, 248, 0.3) !important;
}

.card img {
  border-radius: 12px;
  margin-bottom: 16px;
  width: 100%;
  height: auto;
  object-fit: cover;
  aspect-ratio: 1 / 1;
}

.card h1,
.card h2,
.card h3,
.card h4,
.card h5,
.card h6 {
  color: var(--text) !important;
  margin-top: 8px;
  margin-bottom: 8px;
}

.card small {
  color: var(--secondary);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ========== PROMPT BOX ========== */
.prompt-box {
  background: rgba(2, 6, 23, 0.98) !important;
  border: 1px solid rgba(56, 189, 248, 0.15);
  border-radius: 12px;
  padding: 16px;
  margin: 14px 0;
  color: #c9d1d9 !important;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.9rem;
  line-height: 1.6;
  word-wrap: break-word;
  position: relative;
  flex-grow: 1;
}

.prompt-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  opacity: 0.3;
  border-radius: 12px 12px 0 0;
}

/* ========== BUTTONS ========== */
.btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: 12px;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  transition: all 0.25s ease;
  cursor: pointer;
  border: none;
  font-size: 0.95rem;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), #0ea5e9);
  color: var(--on-accent);
  box-shadow: 0 4px 12px rgba(56, 189, 248, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(56, 189, 248, 0.4);
}

.copy-btn {
  width: 100%;
  padding: 12px 20px;
  margin-top: 12px;
  background: linear-gradient(135deg,
      rgba(56, 189, 248, 0.15),
      rgba(34, 197, 94, 0.15));
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 10px;
  color: var(--text);
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.copy-btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(56, 189, 248, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.copy-btn:hover::before {
  width: 300px;
  height: 300px;
}

.copy-btn:hover {
  background: linear-gradient(135deg,
      rgba(56, 189, 248, 0.25),
      rgba(34, 197, 94, 0.25));
  border-color: rgba(56, 189, 248, 0.5);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(56, 189, 248, 0.3);
}

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

/* ========== SECTIONS ========== */
section {
  padding: 60px 0;
}

.py-5 {
  padding-top: 3rem;
  padding-bottom: 3rem;
}

.mt-4 {
  margin-top: 2rem;
}

.mt-5 {
  margin-top: 3rem;
}

.mb-4 {
  margin-bottom: 2rem;
}

/* ========== GRID SYSTEM ========== */
.row {
  display: flex;
  flex-wrap: wrap;
  margin: 0 -12px;
}

.g-4 {
  gap: 24px;
}

.col-md-6 {
  flex: 0 0 auto;
  width: 100%;
}

.col-lg-4 {
  flex: 0 0 auto;
  width: 100%;
}

@media (min-width: 768px) {
  .col-md-6 {
    width: calc(50% - 24px);
  }
}

@media (min-width: 992px) {
  .col-lg-4 {
    width: calc(33.333% - 24px);
  }
}

/* ========== FOOTER ========== */
footer.site-footer {
  padding: 40px 0;
  border-top: 1px solid var(--border);
  background: rgba(2, 6, 23, 0.5);
  color: var(--muted);
  margin-top: 60px;
}

.site-footer .footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

/* ========== ACCESSIBILITY ========== */
.skip-link {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.skip-link:focus {
  position: fixed;
  left: 8px;
  top: 8px;
  width: auto;
  height: auto;
  padding: 12px 16px;
  border-radius: 8px;
  background: #ffffff;
  color: #000000;
  z-index: 9999;
  box-shadow: var(--shadow-lg);
  font-weight: 600;
}

/* ========== UTILITIES ========== */
a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: #0ea5e9;
  text-decoration: underline;
}

.muted {
  color: var(--muted);
}

.img-hidden {
  display: none !important;
}

.img-fluid {
  max-width: 100%;
  height: auto;
}

/* ========== RESPONSIVE DESIGN ========== */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
  }

  .hero p {
    font-size: 1rem;
  }

  .hero {
    padding: 50px 0 40px;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.75rem;
  }

  h3 {
    font-size: 1.35rem;
  }

  .card {
    padding: 20px !important;
  }

  .copy-btn {
    font-size: 0.8rem;
  }

  .site-nav .nav-inner {
    gap: 20px;
  }

  .site-nav .nav-links {
    gap: 16px;
    font-size: 0.9rem;
  }

  .container {
    padding: 0 16px;
  }
}

@media (max-width: 480px) {
  .site-nav .nav-links {
    display: none;
  }

  .hero h1 {
    font-size: 1.75rem;
  }

  .card {
    padding: 16px !important;
  }
}