:root {
      --ac: #C8801F;
      --ac-lt: #F2D49A;
      --ac-dk: #8B5E0B;

      --teal: #0D6E63;
      --teal-dk: #064E3B;
      --teal-lt: #C5E5DD;

      --amber: #C8801F;
      --amber-lt: #F2D49A;

      --coral: #E85D3C;

      --cream: #FBF5E8;
      --cream-2: #F4ECD7;

      --ink: #0E2A24;
      --muted: #4A5D58;

      --paper: #FFFFFF;

      --rule: rgba(14, 42, 36, 0.1);
    }

/* --- START: Core CSS from mobile.html --- */
    * { box-sizing: border-box; }
    html { scroll-behavior: smooth; }
    body {
        font-family: 'Chiron GoRound TC', 'Noto Sans TC', sans-serif;
        line-height: 1.7;
        margin: 0;
        padding: 0;
        color: var(--ink);
        background: radial-gradient(circle at 12% 0%, rgba(242,212,154,.65), transparent 34%),
                    radial-gradient(circle at 88% 12%, rgba(197,229,221,.75), transparent 34%),
                    linear-gradient(135deg, var(--cream), var(--cream-2));
    }
    .header {
        background: var(--teal-dk);
        color: var(--paper);
        padding: 20px;
        text-align: center;
    }
    .header h1 {
        margin: 0;
        font-size: 1.6em;
        font-weight: 700;
    }
    .header h2 {
        margin: 5px 0 0 0;
        font-size: 1.4em;
        font-weight: 500;
    }
    .main-wrapper {
        max-width: 1000px;
        margin: 0 auto;
        position: relative;
        padding: 20px 0;
    }
    
    .container {
        max-width: 1200px;
        margin: 0 auto;
        padding: 20px;
    }

    .section {
        background: var(--paper);
        margin: 0 0 20px 0;
        padding: 30px;
        border-radius: 16px;
        box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
    }
    h3 {
        color: var(--teal);
        margin-top: 0;
        font-size: 1.6em;
        font-weight: 700;
    }
    h4 {
         color: var(--teal);
         margin-top: 25px;
         font-weight: bold;
    }
    ul, ol { padding-left: 20px; }
    li { margin-bottom: 15px; }
    
    .button {
        font-size: 16px; 
        padding: 12px 22px; 
        margin: 8px 5px 8px 0; 
        border: none;
        border-radius: 6px; 
        cursor: pointer; 
        background-color: var(--teal); 
        color: var(--paper);
        transition: background-color 0.3s;
        text-decoration: none;
        display: inline-block; 
    }
    .button:hover { 
        background-color: var(--teal); 
        color: var(--paper);
    }
    footer {
        margin-top: 40px;
        padding: 20px;
        font-size: 0.8em;
        color: var(--paper);
        background: var(--teal-dk);
        text-align: center;
    }
    footer p { margin: 0; }
    /* --- END: Core CSS from mobile.html --- */


    /* --- START: CSS for new button layout from mobile.html --- */
    .fixed-nav-button {
        position: fixed;
        top: 110px;
        left: 30px; 
        z-index: 1000;
    }
    
    .fixed-nav-button .button {
        margin: 0;
        font-size: 14px;
        padding: 8px 16px;
    }
    
    .mobile-nav-button {
        display: none; 
    }

    @media (max-width: 1200px) {
        .main-wrapper {
            padding: 20px;
        }
        .fixed-nav-button {
            display: none; 
        }
        .mobile-nav-button {
            display: block; 
            margin-bottom: 20px;
        }
        .section + .mobile-nav-button {
            margin-top: 20px;
            margin-bottom: 0;
        }
    }
    @media (max-width: 600px) {
        .main-wrapper { padding: 15px; }
        .header h1 { font-size: 1.5em; }
        .header h2 { font-size: 1.25em; }
        h3 { font-size: 1.15em; }
        .section { padding: 20px 15px; }
        .mobile-nav-button .button { 
            width: 100%; 
            text-align: center; 
            margin: 8px 0;
        }
    }
    /* --- END: CSS for new button layout --- */


    /* --- START: Adapted CSS from mobile.html --- */
    /* This is the header *inside* the white section */
    .main-header-content {
        text-align: center;
        margin-bottom: 40px;
        padding: 20px;
        background: var(--cream-2); 
        border-radius: 12px;
        border: 1px solid var(--teal);
    }
    .main-header-content h1 {
        font-size: clamp(26px, 4vw, 38px);
        color: var(--teal); 
        margin-bottom: 15px;
        font-weight: 700;
    }
    .main-header-content p {
        font-size: clamp(16px, 2.5vw, 18px);
        color: var(--muted); 
        margin-bottom: 10px;
    }
     .main-header-content p:last-child {
        margin-bottom: 0;
    }
    
    .steps-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 25px;
        margin: 30px 0;
    }

    @media (min-width: 768px) {
        .steps-grid {
            grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
        }
    }

    /* Using .step styling from mobile.html */
    .step {
        background: var(--cream); 
        border: 1px solid var(--rule); 
        border-radius: 15px;
        overflow: hidden;
        box-shadow: 0 6px 20px rgba(0,0,0,0.08);
        transition: all 0.3s ease;
        width: 100%;
        display: flex;
        flex-direction: column;
    }
    .step:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 30px rgba(0,0,0,0.12);
        border-color: var(--teal); 
    }
    
    /* NEW style for desktop screenshots, replacing .screenshot-container */
    .step img.desktop-screenshot {
        width: 100%;
        height: auto;
        display: block;
        background: var(--cream-2);
        border-bottom: 1px solid var(--rule);
        cursor: zoom-in;
    }

    .step-content {
        padding: 25px;
    }
    .badge {
        display: inline-block;
        font-size: 13px;
        font-weight: 600;
        background-color: var(--teal);
        color: var(--paper);
        padding: 5px 15px;
        border-radius: 20px;
        margin-bottom: 15px;
    }
    .step h2, .step h3 {
        color: var(--teal); 
        font-size: clamp(18px, 2.5vw, 22px);
        margin-bottom: 12px;
        font-weight: 600;
    }
    .step p {
        color: var(--ink); 
        font-size: clamp(15px, 2vw, 16px);
    }
    .step p:not(:last-child){
        margin-bottom: 8px;
    }
    .step strong {
        color: var(--ink); 
        font-weight: 700;
    }
    .step a {
        color: var(--teal); 
    }
    .step a:hover {
        text-decoration: underline;
    }
    
    /* Modal styles from mobile.html */
    .modal {
        display: none; 
        position: fixed; 
        z-index: 1001;
        padding-top: 60px; 
        left: 0;
        top: 0;
        width: 100%; 
        height: 100%; 
        overflow: auto; 
        background-color: rgba(0,0,0,0.9); 
    }
    .modal-content {
        margin: auto;
        display: block;
        width: 90%;
        max-width: 900px; 
        animation-name: zoom;
        animation-duration: 0.5s;
    }
    @keyframes zoom {
        from {transform:scale(0.8)} 
        to {transform:scale(1)}
    }
    .modal-close {
        position: absolute;
        top: 20px;
        right: 35px;
        color: var(--paper);
        font-size: 40px;
        font-weight: bold;
        transition: 0.3s;
    }
    .modal-close:hover,
    .modal-close:focus {
        color: var(--muted);
        text-decoration: none;
        cursor: pointer;
    }
    /* --- END: Adapted CSS from mobile.html --- */


    /* --- START: Re-styled rules for desktop.html elements --- */

    /* Using CTA buttons from mobile.html, but styles from desktop.html */
    .cta-buttons {
        display: flex;
        flex-wrap: wrap;
        gap: 15px;
        justify-content: center;
        margin: 25px 0;
    }
    .btn {
        display: inline-flex;
        align-items: center;
        padding: 12px 20px;
        background: linear-gradient(135deg, var(--teal) 0%, var(--teal-lt) 100%);
        color: var(--paper);
        text-decoration: none;
        border-radius: 12px;
        font-weight: 600;
        transition: all 0.3s ease;
        box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
        font-size: clamp(14px, 2vw, 16px);
    }
    .btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(76, 175, 80, 0.4);
        filter: brightness(1.1);
    }

    /* NEW light-themed style for desktop's .section-header */
    .section-header {
        background: var(--teal-lt);
        border: 1px solid var(--teal);
        border-radius: 15px;
        padding: 25px;
        margin: 40px 0 30px 0;
        text-align: center;
        box-shadow: 0 6px 20px rgba(0,0,0,0.08);
    }
    .section-header h2 {
        font-size: clamp(20px, 3vw, 28px);
        color: var(--teal);
        margin-bottom: 10px;
    }
    .section-header p {
        color: var(--ink);
        font-size: clamp(14px, 2vw, 16px);
        margin: 0;
    }
    
    /* NEW light-themed style for desktop's .verification-section */
    .verification-section {
        text-align: center;
        margin-top: 40px;
        padding: 30px;
        background-color: var(--cream-2); 
        border-radius: 12px;
        border: 1px solid var(--teal); 
        color: var(--ink);
        box-shadow: 0 6px 20px rgba(0,0,0,0.08);
    }
    .verification-section h2 {
        color: var(--teal);
        font-size: clamp(18px, 3vw, 24px);
        margin-bottom: 15px;
    }
    .verification-section p {
        color: var(--ink);
        font-size: clamp(14px, 2vw, 16px);
        margin-bottom: 20px;
    }

    /* NEW light-themed style for desktop's #ip-display-card */
    #ip-display-card {
        background: var(--paper);
        border: 1px solid var(--rule);
        border-radius: 15px;
        padding: 25px;
        max-width: 500px;
        margin: 20px auto 0;
        box-shadow: 0 6px 20px rgba(0,0,0,0.08);
    }
    #ip-info-loading {
        color: var(--ink);
    }
    #ip-info {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
    #ip-flag {
        width: 40px;
        height: 30px;
        border-radius: 4px;
        border: 1px solid var(--rule);
        box-shadow: 0 4px 10px rgba(0,0,0,0.1);
        object-fit: cover;
    }
    #ip-location {
        font-size: clamp(16px, 2.5vw, 18px);
        font-weight: 600;
        color: var(--teal);
    }
    #ip-address {
        font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
        font-size: clamp(15px, 2.5vw, 17px);
        background: var(--teal-lt);
        padding: 8px 14px;
        border-radius: 10px;
        color: var(--teal);
        border: 1px solid var(--teal);
        word-break: break-all;
    }

    /* NEW light-themed style for desktop's .footer-note */
    .footer-note {
        background: var(--cream);
        border: 1px solid var(--rule);
        border-radius: 12px;
        padding: 20px;
        margin-top: 40px;
        text-align: left;
        color: var(--muted);
        font-size: clamp(13px, 2vw, 15px);
        line-height: 1.6;
    }
    .footer-note p {
        margin: 5px 0;
    }
    
    /* --- END: Re-styled rules --- */


    /* --- VPN test iframe --- */
    .verification-section {
        text-align: center;
        margin-top: 40px;
        padding: 30px;
        background-color: var(--cream-2);
        border-radius: 12px;
        border: 1px solid var(--teal);
        color: var(--ink);
        box-shadow: 0 6px 20px rgba(0,0,0,0.08);
    }
    .verification-section h2 {
        color: var(--teal);
        font-size: clamp(18px, 3vw, 24px);
        margin-bottom: 15px;
    }
    .verification-section p {
        color: var(--ink);
        font-size: clamp(14px, 2vw, 16px);
        margin-bottom: 20px;
    }
    .vpn-test-frame-wrap {
        width: 100%;
        max-width: 900px;
        margin: 20px auto 0;
        border: 1px solid var(--teal);
        border-radius: 15px;
        overflow: hidden;
        background: var(--paper);
        box-shadow: 0 6px 20px rgba(0,0,0,0.08);
    }
    .vpn-test-frame {
        display: block;
        width: 100%;
        min-height: 520px;
        border: 0;
        background: var(--paper);
    }
    .vpn-test-open {
        margin: 14px 0 0 0 !important;
        font-size: clamp(14px, 2vw, 16px);
    }
    .vpn-test-open a {
        color: var(--teal);
        font-weight: 700;
        text-decoration: none;
    }
    .vpn-test-open a:hover {
        text-decoration: underline;
    }
    @media (max-width: 600px) {
        .vpn-test-frame {
            min-height: 620px;
        }
    }

    
    /* --- ACTIVE: course colour scheme applied to all visible components --- */
    body {
        color: var(--ink) !important;
        background:
          radial-gradient(circle at 12% 0%, rgba(242, 212, 154, 0.65), transparent 34%),
          radial-gradient(circle at 88% 12%, rgba(197, 229, 221, 0.75), transparent 34%),
          linear-gradient(135deg, var(--cream), var(--cream-2)) !important;
    }

    .main-wrapper {
        background: transparent !important;
    }

    .section {
        background: var(--paper) !important;
        border: 1px solid var(--rule) !important;
        box-shadow: 0 18px 42px rgba(14, 42, 36, 0.11) !important;
    }

    h1, h2, h3, h4,
    .section-title,
    .main-header-content h1,
    .section-header h2,
    .verification-section h2,
    .step h2,
    .step h3 {
        color: var(--teal) !important;
    }

    p, li, td,
    .step p,
    .main-header-content p,
    .section-header p,
    .verification-section p,
    .footer-note p {
        color: var(--ink) !important;
    }

    strong {
        color: var(--ink) !important;
    }

    a {
        color: var(--teal) !important;
    }

    a:hover {
        color: var(--amber) !important;
    }

    .main-header-content,
    .section-header,
    .verification-section,
    .footer-note {
        background: linear-gradient(135deg, var(--cream), var(--teal-lt)) !important;
        border: 1px solid rgba(13, 110, 99, 0.18) !important;
        box-shadow: 0 10px 26px rgba(14, 42, 36, 0.08) !important;
    }

    .main-header-content {
        border-top: 6px solid var(--amber) !important;
    }

    .section-header {
        border-left: 6px solid var(--teal) !important;
    }

    .verification-section {
        border-top: 6px solid var(--coral) !important;
    }

    .footer-note {
        border-left: 5px solid var(--amber) !important;
    }

    .step {
        background: var(--paper) !important;
        border: 1px solid rgba(13, 110, 99, 0.16) !important;
        box-shadow: 0 10px 25px rgba(14, 42, 36, 0.08) !important;
    }

    .step:hover {
        border-color: var(--amber) !important;
        box-shadow: 0 15px 32px rgba(14, 42, 36, 0.14) !important;
    }

    .screenshot-container {
        background: linear-gradient(135deg, var(--teal-dk), var(--teal)) !important;
    }

    .step img.desktop-screenshot {
        background: var(--cream-2) !important;
        border-bottom: 1px solid var(--rule) !important;
    }

    .badge {
        background: linear-gradient(135deg, var(--amber), var(--ac-dk)) !important;
        color: var(--paper) !important;
    }

    .btn,
    .button {
        background: linear-gradient(135deg, var(--teal), var(--teal-dk)) !important;
        color: var(--paper) !important;
        box-shadow: 0 8px 18px rgba(13, 110, 99, 0.24) !important;
    }

    .btn:hover,
    .button:hover {
        background: linear-gradient(135deg, var(--amber), var(--ac-dk)) !important;
        color: var(--paper) !important;
        box-shadow: 0 10px 24px rgba(200, 128, 31, 0.28) !important;
    }

    .vpn-test-frame-wrap {
        background: var(--paper) !important;
        border: 1px solid rgba(13, 110, 99, 0.24) !important;
        box-shadow: 0 14px 32px rgba(14, 42, 36, 0.10) !important;
    }

    .vpn-test-open a {
        color: var(--teal) !important;
    }

    .vpn-test-open a:hover {
        color: var(--amber) !important;
    }

    #ip-display-card,
    #ip-address {
        background: var(--paper) !important;
        border-color: rgba(13, 110, 99, 0.20) !important;
        color: var(--teal-dk) !important;
    }

    #ip-location {
        color: var(--teal-dk) !important;
    }

    .responsive-table {
        border-collapse: separate !important;
        border-spacing: 0 !important;
        color: var(--muted) !important;
    }

    .responsive-table thead,
    .responsive-table thead tr,
    .responsive-table thead th {
        background: var(--teal-dk) !important;
        color: var(--paper) !important;
        border-color: rgba(255, 255, 255, 0.16) !important;
    }

    .responsive-table tbody tr {
        background: var(--paper) !important;
        border-color: var(--rule) !important;
    }

    .responsive-table tbody tr:hover {
        background: rgba(251, 245, 232, 0.92) !important;
    }

    .responsive-table th[scope="row"] {
        background: rgba(242, 212, 154, 0.44) !important;
        color: var(--teal-dk) !important;
    }

    .responsive-table th[scope="row"] a {
        color: var(--teal-dk) !important;
    }

    .responsive-table td,
    .responsive-table th {
        border-color: var(--rule) !important;
    }

    .responsive-table td::before {
        color: var(--teal-dk) !important;
    }

    .overflow-x-auto {
        border: 1px solid var(--rule) !important;
        border-radius: 18px !important;
        background: var(--paper) !important;
        box-shadow: 0 12px 30px rgba(14, 42, 36, 0.08) !important;
    }

    @media (max-width: 768px) {
        .responsive-table tr {
            background: var(--paper) !important;
            border: 1px solid var(--rule) !important;
        }
        .responsive-table td {
            border-color: var(--rule) !important;
        }
    }

/* --- CH1 page-specific layout and interaction styles --- */
.main-wrapper {
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
    padding: 24px 18px;
}
.container {
    max-width: none;
    margin: 0;
    padding: 0;
}
.section {
    margin: 0 0 24px 0 !important;
    padding: 30px !important;
    border-radius: 18px !important;
    position: relative;
}
.section-content {
    display: block;
}
.section-content img {
    cursor: pointer;
}
h3 {
    margin-top: 0;
    cursor: default;
    font-weight: 700;
}
ul {
    padding-left: 20px;
}
mark {
    background: linear-gradient(180deg, transparent 54%, rgba(242, 212, 154, 0.82) 54%);
    color: var(--ink);
    padding: 0 2px;
}
.info-box {
    background: linear-gradient(135deg, var(--ac-lt), var(--teal-lt));
    padding: 16px 18px;
    border-radius: 12px;
    border-left: 5px solid var(--amber);
    margin-top: 15px;
    color: var(--ink);
}
.email-generator {
    text-align: center;
}
.email-generator h3 {
    margin-bottom: 20px;
    font-size: 24px;
    cursor: default;
}
.email-generator input,
#emojiTextInput {
    margin: 8px auto;
    padding: 12px;
    font-size: 16px;
    width: 100%;
    max-width: 300px;
    border: 1px solid rgba(13, 110, 99, 0.22);
    border-radius: 8px;
    display: block;
    background: var(--paper);
    color: var(--ink);
}
.emailName,
.password {
    font-size: 16px;
    font-weight: bold;
    background-color: var(--cream);
    border-radius: 10px;
    padding: 12px;
    margin: 15px auto;
    word-break: break-all;
    max-width: 300px;
    border: 1px solid rgba(13, 110, 99, 0.18);
    line-height: 1.5;
    color: var(--teal);
}
.password {
    font-size: 24px;
    letter-spacing: 2px;
    padding: 15px;
}
.password.animate {
    animation: fadeSlideUp 0.4s ease;
}
@keyframes fadeSlideUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}
.ip-check-box {
    text-align: center;
    background: var(--cream);
    border: 1px solid var(--teal);
    border-radius: 16px;
    padding: 20px;
    margin: 16px auto 22px;
    max-width: 900px;
    box-shadow: 0 10px 26px rgba(14, 42, 36, 0.08);
}
.ip-check-box p {
    margin-top: 0;
    font-weight: 700;
    color: var(--teal) !important;
}
.ip-check-frame {
    width: 100%;
    min-height: 520px;
    border: 1px solid rgba(13, 110, 99, 0.24);
    border-radius: 14px;
    background: var(--paper);
    box-shadow: 0 14px 32px rgba(14, 42, 36, 0.10);
}
.monitor-warning {
    text-align: center;
    font-size: clamp(18px, 2.6vw, 24px);
    color: var(--coral) !important;
    margin: 0 0 14px;
}
.video-toggle-box {
    text-align: center;
    margin: 18px 0 24px;
}
.video-toggle-button {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-left: auto !important;
    margin-right: auto !important;
}
.video-click-heading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    text-align: center;
    cursor: pointer;
    color: var(--teal) !important;
    margin: 28px auto 14px;
}
.video-click-heading:hover {
    color: var(--amber) !important;
}
.video-panel {
    display: none;
    margin-top: 14px;
}
.video-panel.is-open {
    display: block;
}
.video-panel video {
    box-shadow: 0 10px 26px rgba(14, 42, 36, 0.12);
}
.action-button {
    flex: 1;
    min-width: 150px;
    color: var(--paper);
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.1em;
    transition: background-color 0.2s;
    text-align: center;
}
.generate-button {
     background-color: var(--teal);
}
.generate-button:hover {
    background-color: var(--teal);
}
#image-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 20000;
    padding: 20px;
}
.image-overlay-content {
    max-width: 90vw;
    max-height: 90vh;
    width: auto;
    height: auto;
}
#image-overlay .close-image-btn {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #fff;
    font-size: 50px;
    font-weight: bold;
    text-decoration: none;
    cursor: pointer;
    line-height: 1;
}
#image-overlay .close-image-btn:hover {
    color: var(--ac-lt);
}
@media (max-width: 800px) {
    .main-wrapper {
        padding: 18px 14px;
    }
    .section {
        padding: 22px 16px !important;
    }
}
@media (max-width: 600px) {
    .ip-check-frame {
        min-height: 620px;
    }
    .button {
        width: 100%;
        text-align: center;
        justify-content: center;
        margin: 8px 0 !important;
    }
}

/* Footer - readable light text on dark background */
footer,
footer p,
footer a,
footer h4,
footer .ft-logo,
footer .ft-tag,
footer .ft-btm,
footer .ft-links a {
    color: rgba(255, 255, 255, 0.85) !important;
}
footer a:hover,
footer .ft-links a:hover {
    color: var(--amber-lt) !important;
}

/* Hero support images for the course overview and lesson pages */
.hero-visual-section {
    padding: 0 5vw 70px;
    margin-top: -34px;
    position: relative;
    z-index: 2;
}

.hero-visual-wrap {
    max-width: 1100px;
    margin: 0 auto;
}

.hero-visual {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 12px;
    border: 1px solid var(--rule);
    box-shadow: 0 22px 50px rgba(14, 42, 36, 0.16);
    background: var(--cream-2);
}

@media (max-width: 700px) {
    .hero-visual-section {
        padding: 0 5vw 46px;
        margin-top: -24px;
    }

    .hero-visual {
        aspect-ratio: 4 / 3;
        border-radius: 10px;
        box-shadow: 0 14px 32px rgba(14, 42, 36, 0.14);
    }
}

