/* Custom CSS for FastNotes Landing Pages */
/* Most styling is handled by Tailwind CSS via CDN */

/* ============================================
   Base Responsive Styles
   ============================================ */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

/* Prevent horizontal scroll on mobile */
body {
    overflow-x: hidden;
}

/* Custom focus styles for accessibility */
*:focus {
    outline: 2px solid #9c27b0;
    outline-offset: 2px;
}

/* Remove focus ring for mouse users */
*:focus:not(:focus-visible) {
    outline: none;
}

/* ============================================
   Touch-Friendly Interactions
   ============================================ */

/* Minimum touch target size (44px per WCAG) */
@media (max-width: 768px) {
    button,
    a,
    [role="button"],
    input[type="submit"],
    input[type="button"] {
        min-height: 44px;
        min-width: 44px;
    }

    /* Larger touch padding for links */
    nav a {
        padding: 12px 16px;
    }
}

/* Prevent text selection on interactive elements */
button,
[role="button"] {
    -webkit-user-select: none;
    user-select: none;
}

/* ============================================
   Tab Button Styles
   ============================================ */
.tab-btn {
    background-color: #f3f4f6;
    color: #4b5563;
    min-height: 44px;
    padding: 8px 16px;
}

.tab-btn:hover {
    background-color: #e5e7eb;
}

.tab-btn.active {
    background-color: #9c27b0;
    color: white;
}

/* Responsive tab sizing */
@media (max-width: 640px) {
    .tab-btn {
        padding: 10px 12px;
        font-size: 0.875rem;
    }
}

/* ============================================
   FAQ Accordion
   ============================================ */
.faq-toggle i.rotate-180 {
    transform: rotate(180deg);
}

.faq-content {
    transition: max-height 0.3s ease-out;
}

/* Larger touch target for FAQ on mobile */
@media (max-width: 768px) {
    .faq-toggle {
        padding: 16px 20px;
    }
}

/* ============================================
   Animations
   ============================================ */
@keyframes gradient-shift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.animate-gradient {
    background-size: 200% 200%;
    animation: gradient-shift 15s ease infinite;
}

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

.spinner {
    border: 3px solid #f3f4f6;
    border-top: 3px solid #9c27b0;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    animation: spin 1s linear infinite;
}

/* Reduce animations for users who prefer reduced motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ============================================
   Mobile Menu
   ============================================ */
#mobile-menu {
    transition: max-height 0.3s ease-out, opacity 0.3s ease-out;
}

#mobile-menu a {
    display: block;
    padding: 12px 0;
}

/* ============================================
   Card Hover Effects
   ============================================ */
.card-hover {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Only apply hover effects on devices that support hover */
@media (hover: hover) and (pointer: fine) {
    .card-hover:hover {
        transform: translateY(-4px);
        box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    }
}

/* Active state for touch devices */
.card-hover:active {
    transform: scale(0.98);
}

/* Button press effect */
button:active,
a:active {
    transform: scale(0.98);
}

/* ============================================
   Responsive Typography
   ============================================ */

/* Hero text - responsive sizing */
.hero-title {
    font-size: clamp(1.75rem, 5vw, 3.75rem);
    line-height: 1.1;
}

.hero-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    line-height: 1.6;
}

/* ============================================
   Prose Styles (Static Content Pages)
   ============================================ */
.prose h1 {
    font-size: clamp(1.5rem, 4vw, 2.25rem);
    font-weight: 700;
    margin-bottom: 1rem;
    color: #111827;
}

.prose h2 {
    font-size: clamp(1.25rem, 3vw, 1.5rem);
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: #1f2937;
}

.prose h3 {
    font-size: clamp(1.1rem, 2.5vw, 1.25rem);
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    color: #374151;
}

.prose p {
    margin-bottom: 1rem;
    line-height: 1.75;
}

.prose ul, .prose ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.prose li {
    margin-bottom: 0.5rem;
}

.prose a {
    color: #9c27b0;
    text-decoration: underline;
}

.prose a:hover {
    color: #7b1fa2;
}

/* Responsive video container */
.video-responsive {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 aspect ratio */
    overflow: hidden;
}

.video-responsive iframe,
.video-responsive video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Hide scrollbar but keep functionality */
.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.scrollbar-hide::-webkit-scrollbar {
    display: none;
}
