/* ==================== FONT FACES ==================== */
@font-face {
    font-family: 'CalSans';
    src: url('../assets/fonts/CalSans-Regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'DM Sans';
    src: url('../assets/fonts/DMSans_24pt-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: 'DM Sans';
    src: url('../assets/fonts/DMSans_24pt-SemiBold.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
}

/* ==================== RESET & BASE ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: #E9E9E9;
    color: #333333;
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow: hidden; /* Prevent scrolling but allow children to overflow visually */
    height: 100vh;
}

a {
    text-decoration: none;
    color: inherit;
}

button {
    border: none;
    background: none;
    cursor: pointer;
    font-family: inherit;
}

ul {
    list-style-position: inside;
}

/* ==================== LEDGEY HEADER ==================== */
.ledgey-header {
    padding: 20px 60px 10px; /* Reduced top padding */
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1400px;
    margin: 0 auto;
    gap: 24px; /* Add gap between header elements for spacing */
}

.ledgey-logo {
    height: 80px; /* 100% larger (2x original 40px) */
    width: auto;
    margin-right: 8px; /* Add spacing between logo and nav pill */
    margin-left: 0;
    flex-shrink: 0;
    display: block;
}

.header-container > a {
    margin: 0;
    padding: 0;
    line-height: 0;
    display: block;
    flex-shrink: 0;
}

.northlyne-logo {
    height: 32px;
    width: auto;
    margin-left: 8px; /* Add spacing between nav pill and logo */
    flex-shrink: 0;
}

.combined-logo {
    height: 64px;
    width: auto;
    flex-shrink: 0;
}

.mobile-only-logo {
    display: none;
}

.desktop-only-logo {
    display: block;
}

/* Desktop Navigation */
.desktop-nav {
    display: flex;
    align-items: center;
    gap: 0;
    background: white;
    border-radius: 50px;
    padding: 7.5px 12px; /* Reduced horizontal padding to hug the gray pills */
    flex-shrink: 1;
    min-width: 0;
    overflow: hidden;
}

.desktop-nav a {
    font-family: 'DM Sans', sans-serif;
    font-size: 15px; /* 50% bigger than previous 10px */
    font-weight: 400;
    color: #333333;
    padding: 6px 36px; /* Reduced vertical padding by 25% (was 8px, now 6px) */
    border-radius: 50px;
    transition: background-color 0.2s;
    position: relative;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
    flex-shrink: 1;
    min-width: 0;
}

.desktop-nav a.active {
    background-color: #F0F0F0;
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    margin: 0;
    padding: 0;
}

.mobile-menu-btn img {
    height: 12px;
    width: auto;
    display: block;
}

/* ==================== MOBILE NAVIGATION OVERLAY ==================== */
.mobile-nav-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s;
}

.mobile-nav-overlay.active {
    display: flex;
    opacity: 1;
}

.mobile-nav-sheet {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    border-radius: 12px 12px 0 0;
    padding: 24px;
    transform: translateY(100%);
    transition: transform 0.3s;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.mobile-nav-overlay.active .mobile-nav-sheet {
    transform: translateY(0);
}

.mobile-nav-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.mobile-nav-logo {
    height: 32px;
    width: auto;
}

.mobile-nav-close {
    padding: 8px;
}

.mobile-nav-close img {
    width: 30px;
    height: 30px;
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.mobile-nav-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-bottom: 1px solid #E0E0E0;
    font-family: 'DM Sans', sans-serif;
    font-weight: 600;
    font-size: 16px;
    color: #333333;
}

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

.mobile-nav-item img {
    width: 32px;
    height: 32px;
}

.mobile-nav-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding-top: 24px;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    color: #333333;
}

.mobile-nav-footer .copyright-icon {
    width: 12px;
    height: 12px;
}

/* ==================== MAIN CONTENT - HOMEPAGE ==================== */
main {
    max-width: 1800px; /* Increased from 1400px to allow more space */
    margin: 0 auto;
    padding: 0 60px 0; /* Remove bottom padding */
    display: flex;
    flex-direction: column;
    height: calc(100vh - 100px); /* Adjusted for reduced header padding */
    overflow: visible; /* Allow overflow in all directions */
    position: relative; /* For absolute positioning of indicators */
}

/* Features Section */
.features-section {
    display: flex;
    align-items: center;
    justify-content: center; /* Center the content */
    margin: 15px 0 10px; /* Reduced bottom margin */
    position: relative;
    gap: 20px; /* Gap between arrows and content */
}

.features-content {
    text-align: center;
    width: 600px; /* Fixed width to keep arrows in consistent position */
    min-height: 0; /* Remove minimum height */
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.feature-title {
    font-family: 'CalSans', sans-serif;
    font-size: 32px;
    font-weight: normal;
    color: #333333;
    margin-bottom: 16px;
    height: 40px; /* Fixed height for title */
    display: flex;
    align-items: center;
    justify-content: center;
}

.feature-description {
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    font-weight: 400;
    color: #333333;
    line-height: 1.5;
    min-height: 45px; /* Fixed minimum height for 2 lines (15px * 1.5 * 2) */
    display: flex;
    align-items: flex-start; /* Align text to top */
    justify-content: center;
}

.arrow-btn {
    padding: 12px;
    transition: opacity 0.2s;
    flex-shrink: 0; /* Prevent arrows from shrinking */
    align-self: center; /* Center vertically within the section */
    position: relative;
    z-index: 100; /* Ensure arrows are above other elements */
    cursor: pointer;
}

.arrow-btn:hover {
    opacity: 0.7;
}

.arrow-btn img {
    width: 80px; /* 200% bigger (was 40px) */
    height: 80px;
    display: block;
}

/* App Store Badge */
.app-store-container {
    display: flex;
    justify-content: center;
    margin: 0 0 20px;
}

.app-store-link {
    display: block;
    transition: opacity 0.2s;
}

.app-store-link:hover {
    opacity: 0.8;
}

.app-store-link img {
    height: 50px;
    width: auto;
}

/* iPhone Wheel */
.iphone-wheel-container {
    display: flex;
    justify-content: center;
    align-items: flex-start; /* Changed from center to flex-start */
    margin: 0;
    min-height: 0;
    position: relative;
    overflow: visible; /* Allow edges to show */
    flex: 1; /* Take up all remaining space */
    margin-bottom: -15px; /* Pull down to eliminate gap (matches indicator padding) */
    background: transparent; /* Ensure no background obstruction */
    pointer-events: none; /* Allow clicks to pass through */
}

.iphone-wheel {
    min-width: 1680px;
    width: 1680px;
    max-width: none;
    height: auto;
    transition: transform 0.3s cubic-bezier(0.68, 0, 0.265, 1.55);
    transform-origin: center center;
    position: relative;
    top: 0;
    flex-shrink: 0;
    pointer-events: none;
}

/* Feature Indicators */
.feature-indicators {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 7px;
    margin: 10px 0 10px 0; /* Top and bottom margin */
    padding: 0;
    position: relative; /* Position in normal flow */
    background: transparent;
    z-index: 10;
}

.indicator {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background-color: #CCCCCC;
    transition: all 0.3s;
}

.indicator.active {
    width: 12px;
    height: 12px;
    background-color: #888888;
}

/* ==================== CONTENT PAGES ==================== */
.content-page {
    padding: 0 60px 0; /* Remove bottom padding */
    overflow-y: auto; /* Allow scrolling on content pages */
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.content-container {
    max-width: 900px;
    margin: 0 auto;
    flex: 0 0 auto;
    padding-bottom: 40px;
}

.page-title {
    font-family: 'CalSans', sans-serif;
    font-size: 32px;
    font-weight: normal;
    color: #333333;
    text-align: center;
    margin-top: 40px; /* Increased gap from header */
    margin-bottom: 12px;
}

.effective-date {
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    font-weight: 400;
    color: #333333;
    text-align: center;
    margin-bottom: 48px;
}

.content-section {
    margin-bottom: 36px;
}

.content-section h2 {
    font-family: 'CalSans', sans-serif;
    font-size: 24px;
    font-weight: normal;
    color: #333333;
    margin-bottom: 16px;
}

.content-section h3 {
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #333333;
    margin-bottom: 12px;
    margin-top: 24px;
}

.content-section p {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #333333;
    line-height: 1.7;
    margin-bottom: 12px;
}

.content-section ul {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #333333;
    line-height: 1.7;
    margin-bottom: 12px;
    padding-left: 20px;
}

.content-section li {
    margin-bottom: 8px;
}

.content-section strong {
    font-weight: 600;
}

/* Support Page Specific */
.support-page .content-container {
    padding-bottom: 20px;
}

.support-subtitle {
    font-family: 'CalSans', sans-serif;
    font-size: 24px;
    font-weight: normal;
    color: #333333;
    text-align: left;
    margin-bottom: 32px;
    margin-top: 32px;
}

.support-content {
    max-width: 700px;
    margin: 0 auto;
}

.support-content p {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #333333;
    line-height: 1.7;
    margin-bottom: 16px;
}

.contact-info {
    margin: 24px 0;
}

.contact-info p {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #333333;
    line-height: 1.7;
    margin-bottom: 0;
}

.company-name {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #333333;
    margin-bottom: 0;
}

.email-contact {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #333333;
    margin-bottom: 0;
}

.email-contact a {
    color: #333333;
    transition: opacity 0.2s;
}

.email-contact a:hover {
    opacity: 0.7;
}

.envelope-icon {
    display: none;
}

/* Page Footer */
.page-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: auto;
    padding: 40px 0;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    color: #333333;
    flex-shrink: 0;
}

.page-footer .copyright-icon {
    width: 14px;
    height: 14px;
}

.footer-spacer {
    height: 120px;
    flex-shrink: 0;
}

/* ==================== RESPONSIVE - TABLET ==================== */
@media screen and (max-width: 1024px) {
    .ledgey-header {
        padding: 15px 40px 8px; /* Reduced top padding */
    }

    main {
        padding: 0 40px;
        height: calc(100vh - 80px);
    }

    .features-section {
        margin: 20px 0 15px; /* Reduced bottom margin to half */
    }

    .features-content {
        min-height: 76px; /* Reduced to minimize gap */
    }

    .feature-title {
        font-size: 28px;
        height: 36px; /* Adjusted for smaller font */
    }

    .feature-description {
        font-size: 13.5px;
        min-height: 40.5px; /* Adjusted for smaller font (13.5px * 1.5 * 2) */
    }

    .app-store-container {
        margin: 0 0 20px; /* Removed top margin */
    }

    .arrow-btn img {
        width: 64px;
        height: 64px;
    }

    .content-page {
        padding: 0 40px 40px;
    }
}

/* ==================== RESPONSIVE - MOBILE ==================== */
@media screen and (max-width: 768px) {
    .ledgey-header {
        padding: 20px 24px 5px; /* Increased top padding for mobile */
    }

    .header-container {
        gap: 8px; /* Reduced gap for mobile */
    }

    .ledgey-logo {
        height: 64px; /* 100% larger (2x original mobile size) */
        margin-right: 6px; /* Spacing between logo and nav pill */
        margin-left: -20px; /* Negative margin to close gap with hamburger icon */
    }

    .header-container > a {
        margin-left: -20px; /* Pull linked logo closer to hamburger */
    }

    .northlyne-logo {
        height: 24px;
        margin-left: 6px; /* Spacing between nav pill and logo */
    }

    /* Show mobile menu button, hide desktop nav */
    .desktop-nav {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    /* Hide desktop logos, show combined logo */
    .desktop-only-logo {
        display: none !important;
    }

    .mobile-only-logo {
        display: block;
    }

    .combined-logo {
        height: 64px;
        margin: 0;
    }

    .mobile-nav-logo {
        height: 64px; /* Match mobile ledgey logo size */
    }

    /* Main Content */
    main {
        padding: 0 24px;
        height: calc(100vh - 80px);
    }

    .features-section {
        margin: 15px 0 12px; /* Reduced bottom margin to half */
    }

    .features-content {
        max-width: 100%;
        min-height: 66px; /* Reduced to minimize gap */
    }

    .feature-title {
        font-family: 'CalSans', sans-serif;
        font-size: 24px;
        margin-bottom: 12px;
        height: 30px; /* Fixed height for mobile title */
    }

    .feature-description {
        font-size: 12px;
        min-height: 36px; /* Fixed minimum height (12px * 1.5 * 2) */
    }

    .app-store-container {
        margin: 0 0 15px; /* Removed top margin */
    }

    .app-store-link img {
        height: 44px;
    }

    .iphone-wheel-container {
        margin: 0;
        margin-bottom: -12px;
        min-height: 0;
    }

    .iphone-wheel {
        min-width: 1848px; /* 10% larger: 1680px * 1.1 */
        width: 1848px;
    }

    .feature-indicators {
        gap: 6px;
        margin: 0;
        padding: 12px 0;
    }

    .indicator {
        width: 8px;
        height: 8px;
    }

    .indicator.active {
        width: 10px;
        height: 10px;
    }

    /* Content Pages */
    .content-page {
        padding: 0 24px 0; /* Remove bottom padding */
    }

    .content-container {
        max-width: 100%;
        padding-bottom: 30px;
    }

    .page-title {
        font-size: 28px;
        margin-top: 30px; /* Increased gap from header on mobile */
        margin-bottom: 10px;
    }

    .effective-date {
        font-size: 14px;
        margin-bottom: 36px;
    }

    .content-section {
        margin-bottom: 28px;
    }

    .content-section h2 {
        font-size: 20px;
        margin-bottom: 14px;
    }

    .content-section h3 {
        font-size: 15px;
        margin-bottom: 10px;
        margin-top: 20px;
    }

    .support-subtitle {
        font-size: 20px;
        margin-bottom: 24px;
    }

    .contact-info {
        margin: 20px 0;
    }

    .page-footer {
        padding: 30px 0;
    }

    .footer-spacer {
        height: 80px;
    }

    .support-page .content-container {
        padding-bottom: 10px;
    }
}

/* ==================== RESPONSIVE - SMALL MOBILE ==================== */
@media screen and (max-width: 480px) {
    .ledgey-header {
        padding: 8px 20px 4px; /* Reduced top padding */
    }

    .ledgey-logo {
        height: 56px; /* 100% larger (2x original small mobile size) */
        margin-right: 4px; /* Spacing between logo and nav pill */
    }

    .northlyne-logo {
        height: 20px;
        margin-left: 4px; /* Spacing between nav pill and logo */
    }

    main {
        padding: 0 20px;
        height: calc(100vh - 68px);
    }

    .features-section {
        margin: 12px 0 10px; /* Reduced bottom margin to half */
    }

    .features-content {
        min-height: 60px; /* Reduced to minimize gap */
    }

    .feature-title {
        font-size: 22px;
        height: 28px; /* Fixed height for small mobile title */
    }

    .feature-description {
        font-size: 11.25px;
        min-height: 33.75px; /* Fixed minimum height (11.25px * 1.5 * 2) */
    }

    .app-store-container {
        margin: 0 0 12px; /* Removed top margin */
    }

    .arrow-btn img {
        width: 56px; /* 200% bigger than original small mobile (was 28px) */
        height: 56px;
    }

    .iphone-wheel-container {
        min-height: 0;
        margin: 0 0 -10px 0; /* Negative margin to eliminate gap */
    }

    .feature-indicators {
        margin: 0;
        padding: 10px 0;
    }

    .content-page {
        padding: 0 20px 30px;
    }

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

    .content-section h2 {
        font-size: 18px;
    }

    .support-subtitle {
        font-size: 18px;
    }
}
