/* Premium Tools Design System */
:root {
  --tool-primary: #6366f1;
  --tool-secondary: #a855f7;
  --tool-accent: #f43f5e;
  --tool-bg-dark: #0f172a;
  --glass-bg: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.1);
}

.premium-tool-hero {
  position: relative;
  padding: 120px 0 80px;
  background: radial-gradient(circle at top right, rgba(99, 102, 241, 0.15), transparent),
              radial-gradient(circle at bottom left, rgba(244, 63, 94, 0.1), transparent),
              var(--tool-bg-dark);
  color: white;
  overflow: hidden;
}

.premium-tool-hero::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%239C92AC' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2v-4h4v-2h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2v-4h4v-2H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.premium-badge {
  display: inline-block;
  padding: 6px 16px;
  background: linear-gradient(90deg, var(--tool-primary), var(--tool-secondary));
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 24px;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.premium-title {
  font-size: clamp(2.5rem, 8vw, 4.5rem);
  line-height: 1.1;
  margin-bottom: 24px;
  background: linear-gradient(to bottom right, #fff, #94a3b8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 800;
}

.premium-subtitle {
  font-size: 1.25rem;
  color: #94a3b8;
  max-width: 700px;
  margin: 0 auto 40px;
}

/* Glassmorphism Cards */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 40px;
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.glass-card:hover {
  transform: translateY(-10px);
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
}

/* Feature Grid */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: -60px;
  position: relative;
  z-index: 10;
}

/* Dynamic Gradients */
.gradient-text {
  background: linear-gradient(90deg, #6366f1, #a855f7, #f43f5e);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 700;
}

/* Animations */
.reveal-up {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.reveal-up.active {
  opacity: 1;
  transform: translateY(0);
}

.floating {
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-20px); }
  100% { transform: translateY(0px); }
}

/* Content Sections */
.rich-content-section {
  padding: 100px 0;
  background: #fff;
  color: #1e293b;
}

.content-block {
  max-width: 900px;
  margin: 0 auto;
}

.content-block h2 {
  font-size: 2.5rem;
  margin-bottom: 30px;
  color: #0f172a;
}

.content-block p {
  font-size: 1.15rem;
  line-height: 1.8;
  margin-bottom: 24px;
  color: #475569;
}

.content-block ul {
  padding-left: 24px;
  margin-bottom: 30px;
}

.content-block li {
  font-size: 1.15rem;
  line-height: 1.8;
  margin-bottom: 16px;
  color: #475569;
}

.glass-panel {
  padding: 40px !important; 
}

/* FAQ Accordion Premium */
.faq-container {
  margin-top: 80px;
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
}

.faq-item {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  margin-bottom: 16px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:hover {
  border-color: var(--tool-primary);
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.1);
}

.faq-question {
  padding: 24px 32px;
  font-size: 1.2rem;
  font-weight: 700;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #0f172a;
  cursor: pointer;
  user-select: none;
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  color: #475569;
  font-size: 1.1rem;
  line-height: 1.7;
  padding: 0 32px;
}

.faq-item.active {
  background: #fff;
  border-color: var(--tool-primary);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.faq-item.active .faq-answer {
  max-height: 500px;
  padding-bottom: 32px;
}

.faq-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: rgba(99, 102, 241, 0.1);
  color: var(--tool-primary);
  border-radius: 50%;
  transition: all 0.3s ease;
}

.faq-item.active .faq-toggle {
  background: var(--tool-primary);
  color: white;
  transform: rotate(180deg);
}

/* Input Area Premium */
.tool-input-container {
  max-width: 700px;
  margin: 0 auto;
  position: relative;
}

.premium-input {
  width: 100%;
  padding: 20px 30px;
  font-size: 1.2rem;
  border-radius: 100px;
  border: 2px solid transparent;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  outline: none;
  transition: all 0.3s ease;
}

.premium-input:focus {
  border-color: var(--tool-primary);
  box-shadow: 0 10px 40px rgba(99, 102, 241, 0.2);
}

.premium-tool-btn {
  position: absolute;
  right: 8px;
  top: 8px;
  bottom: 8px;
  padding: 0 35px;
  border-radius: 100px;
  background: linear-gradient(90deg, var(--tool-primary), var(--tool-secondary));
  color: white;
  border: none;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.premium-tool-btn:hover {
  transform: scale(1.05);
}

/* Responsive */
@media (max-width: 768px) {
  .premium-title {
    font-size: 2.5rem;
  }
  .premium-tool-hero {
    padding: 80px 0 60px;
  }
  .feature-grid {
    margin-top: 20px;
  }
  .premium-tool-btn {
    position: static;
    width: 100%;
    margin-top: 15px;
    height: 55px;
  }
  .premium-input {
    border-radius: 16px;
  }
}

/* Overriding Styles for Premium Tool Pages (.premium-hero, .hero-title-main, .hero-subtitle-main) */
h1.hero-title-main,
.premium-hero h1,
.premium-hero .hero-title-main {
  color: #f8fafc !important;
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.8), 0 2px 4px rgba(255, 255, 255, 0.3) !important;
  font-size: clamp(2rem, 6vw, 4.2rem) !important;
  font-weight: 900 !important;
  line-height: 1.15 !important;
  margin-bottom: 20px !important;
  padding: 0 16px !important;
  letter-spacing: -1px !important;
  background: linear-gradient(135deg, #ffffff 0%, #cbd5e1 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.premium-hero p.hero-subtitle-main,
.premium-hero .hero-subtitle-main {
  color: #e2e8f0 !important;
  font-size: clamp(1rem, 2.5vw, 1.25rem) !important;
  line-height: 1.6 !important;
  max-width: 720px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: 0 16px !important;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.6) !important;
}

/* Ensure the fixed header on all premium tool pages has a solid/frosted dark backdrop so scrolling text never clashes with navigation */
header.header {
  background: rgba(15, 23, 42, 0.92) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5) !important;
}

/* Ensure headings inside dark premium tool sections are bright white / high contrast */
.premium-hero h2, .premium-hero h3, .premium-hero h4, .premium-hero h5, .premium-hero h6,
.premium-tool-hero h2, .premium-tool-hero h3, .premium-tool-hero h4, .premium-tool-hero h5, .premium-tool-hero h6,
.guide-article h2, .guide-article h3, .guide-article h4, .guide-article h5, .guide-article h6,
.tutorial-step h3,
.card-vibrant h3,
[style*="background: #020617"] h2, [style*="background: #020617"] h3, [style*="background: #020617"] h4,
[style*="background: #0f172a"] h2, [style*="background: #0f172a"] h3, [style*="background: #0f172a"] h4,
.bg-dark h2, .bg-dark h3, .bg-dark h4, .bg-dark h5, .bg-dark h6,
.bg-darker h2, .bg-darker h3, .bg-darker h4, .bg-darker h5, .bg-darker h6 {
  color: #f8fafc !important;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.6) !important;
  letter-spacing: -0.5px !important;
}

/* Ensure description paragraphs in dark feature cards, tutorial steps, and guide articles maintain high readability */
.card-vibrant p,
.tutorial-step p,
.guide-article p,
.guide-article ul li,
[style*="background: #020617"] p,
[style*="background: #0f172a"] p,
.bg-dark p,
.bg-darker p {
  color: #cbd5e1 !important;
  line-height: 1.7 !important;
}

/* Highlight specific emphasis text in guide articles */
.guide-article strong,
.guide-article b,
[style*="background: #020617"] strong,
[style*="background: #0f172a"] strong {
  color: #f8fafc !important;
  font-weight: 700 !important;
}

/* Premium FAQ Accordion System */
.faq-dark-item {
  background: rgba(255, 255, 255, 0.03) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 20px !important;
  margin-bottom: 16px !important;
  overflow: hidden !important;
  transition: all 0.3s ease !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2) !important;
}

.faq-dark-item:hover {
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(168, 85, 247, 0.4) !important;
  transform: translateY(-2px) !important;
}

.faq-dark-question {
  padding: 24px !important;
  font-weight: 600 !important;
  font-size: 1.15rem !important;
  cursor: pointer !important;
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  color: #f8fafc !important;
  user-select: none !important;
}

.faq-dark-question i {
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
  color: #a855f7 !important;
  width: 20px !important;
  height: 20px !important;
}

.faq-dark-answer {
  padding: 0 24px !important;
  max-height: 0 !important;
  opacity: 0 !important;
  overflow: hidden !important;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
  color: #cbd5e1 !important;
  line-height: 1.7 !important;
  font-size: 1rem !important;
}

.faq-dark-item.active .faq-dark-question i {
  transform: rotate(180deg) !important;
}

.faq-dark-item.active .faq-dark-answer {
  padding: 0 24px 24px !important;
  max-height: 500px !important;
  opacity: 1 !important;
  border-top: 1px solid rgba(255, 255, 255, 0.05) !important;
  margin-top: 8px !important;
}

