:root {
    --bg-app: #f8fafc;
    --bg-card: #ffffff;
    --bg-input: #f1f5f9;
    --border-color: #e2e8f0;
    --border-active: #0f172a;
    
    --text-title: #0f172a;
    --text-body: #334155;
    --text-sub: #64748b;
    --text-muted: #94a3b8;
    
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-subtle: #eff6ff;
    --green: #16a34a;
    
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-full: 9999px;
    
    --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.03);
    --shadow-float: 0 8px 24px rgba(15, 23, 42, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--bg-app);
    color: var(--text-body);
    line-height: 1.45;
    padding-bottom: 80px; /* Space for mobile bottom bar */
}

/* Top App Bar (Native Mobile Header) */
.app-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    padding: 12px 16px;
}

.header-container {
    max-width: 680px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.app-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--text-title);
}

.brand-logo {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: var(--text-title);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.brand-title {
    font-size: 17px;
    font-weight: 700;
    letter-spacing: -0.3px;
}

.brand-badge {
    font-size: 11px;
    font-weight: 600;
    background: #e2e8f0;
    color: #475569;
    padding: 2px 7px;
    border-radius: 6px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-header-icon {
    background: var(--bg-input);
    border: none;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-body);
    font-size: 14px;
    cursor: pointer;
}

/* Mobile Main Container */
.app-content {
    max-width: 680px;
    margin: 0 auto;
    padding: 16px;
}

/* Hero Banner for Mobile */
.mobile-hero {
    text-align: center;
    padding: 12px 4px 18px;
}

.hero-headline {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-title);
    line-height: 1.3;
    letter-spacing: -0.4px;
    margin-bottom: 6px;
}

.hero-sub {
    font-size: 13px;
    color: var(--text-sub);
    line-height: 1.4;
}

/* Main Downloader Card */
.main-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 16px;
    box-shadow: var(--shadow-card);
    margin-bottom: 20px;
}

/* Type Picker (Dropdown) */
.type-picker-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--bg-input);
    border-radius: var(--radius-md);
    padding: 8px 12px;
    margin-bottom: 12px;
}

.type-picker-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-sub);
    display: flex;
    align-items: center;
    gap: 6px;
}

.type-picker-select {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 12.5px;
    font-weight: 600;
    color: var(--text-title);
    outline: none;
    max-width: 180px;
    cursor: pointer;
}

/* Input Group */
.input-group {
    position: relative;
    margin-bottom: 10px;
}

.input-control {
    width: 100%;
    height: 48px;
    background: #ffffff;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 0 74px 0 14px;
    font-size: 14px;
    color: var(--text-title);
    outline: none;
    transition: border-color 0.15s ease;
}

.input-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.input-control::placeholder {
    color: var(--text-muted);
    font-size: 13px;
}

.btn-paste-pill {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-body);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
}

.btn-paste-pill:active {
    background: #e2e8f0;
}

/* Large Download Action Button (Warna Biru) */
.btn-action-main {
    width: 100%;
    height: 48px;
    background: var(--primary);
    color: #ffffff;
    border: none;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: transform 0.1s ease, background-color 0.15s;
    box-shadow: 0 2px 6px rgba(37, 99, 235, 0.25);
}

.btn-action-main:hover {
    background: var(--primary-hover);
}

.btn-action-main:active {
    transform: scale(0.98);
}

/* Badges / Guarantees */
.quick-badges {
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding-top: 14px;
    margin-top: 12px;
    border-top: 1px dashed var(--border-color);
    font-size: 11.5px;
    color: var(--text-sub);
    font-weight: 500;
}

.quick-badges span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.quick-badges i {
    color: var(--green);
    font-size: 12px;
}

/* Result Preview Card (Mobile Optimized & Clean) */
.result-box {
    display: none;
    margin-top: 16px;
    padding: 14px;
    background: #ffffff;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-card);
}

.result-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.result-thumb-img {
    width: 76px;
    height: 76px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid var(--border-color);
    background: #cbd5e1;
}

.result-thumb-mp3 {
    width: 76px;
    height: 76px;
    border-radius: 10px;
    background: var(--text-title);
    color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    flex-shrink: 0;
}

.result-thumb-mp3 i {
    font-size: 24px;
}

.result-thumb-mp3 span {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.result-info-text {
    flex: 1;
    min-width: 0;
}

.res-tag {
    display: inline-block;
    font-size: 10.5px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--primary);
    background: var(--primary-subtle);
    padding: 2px 7px;
    border-radius: 4px;
    margin-bottom: 4px;
    letter-spacing: 0.2px;
}

.res-title {
    font-size: 13.5px;
    font-weight: 600;
    color: var(--text-title);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.35;
    margin-bottom: 6px;
}

.res-specs {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    align-items: center;
}

.spec-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    color: var(--text-sub);
    background: var(--bg-input);
    padding: 2px 7px;
    border-radius: 5px;
    border: 1px solid var(--border-color);
    font-weight: 500;
}

.spec-pill i {
    font-size: 10px;
    color: var(--text-muted);
}

/* Resolution / Format Dropdown in Result Box */
.format-picker-container {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px dashed var(--border-color);
}

.format-picker-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-sub);
    margin-bottom: 6px;
}

.format-select-wrapper {
    position: relative;
}

.format-select-control {
    width: 100%;
    height: 40px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 0 34px 0 12px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-title);
    cursor: pointer;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    transition: all 0.15s ease;
}

.format-select-control:focus, .format-select-control:hover {
    border-color: var(--primary);
    background: #ffffff;
}

.select-chevron {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 11px;
    color: var(--text-muted);
    pointer-events: none;
}

.download-action-single {
    margin-top: 10px;
}

.btn-download-main {
    width: 100%;
    height: 44px;
    background: var(--primary);
    color: #ffffff;
    border: none;
    border-radius: var(--radius-md);
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.15s ease;
    box-shadow: 0 1px 3px rgba(37, 99, 235, 0.2);
}

.btn-download-main:hover {
    background: var(--primary-hover);
}

.btn-download-main:active {
    transform: scale(0.98);
}

/* Instagram Profile Result Box (Modern & Sleek) */
.profile-result-box {
    display: none;
    margin-top: 16px;
    padding: 16px;
    background: #ffffff;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-card);
}

.profile-card-header {
    display: flex;
    align-items: center;
    gap: 14px;
}

.profile-avatar-wrapper {
    position: relative;
    width: 76px;
    height: 76px;
    padding: 3px;
    border-radius: 50%;
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    box-shadow: 0 3px 12px rgba(188, 24, 136, 0.28);
    flex-shrink: 0;
}

.profile-avatar-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #ffffff;
    background: #e2e8f0;
    display: block;
}

.profile-badge-verified {
    position: absolute;
    bottom: 0;
    right: 0;
    background: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #c13584;
    font-size: 15px;
    line-height: 1;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

.profile-info-text {
    flex: 1;
    min-width: 0;
}

.profile-fullname {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-title);
    margin: 3px 0 2px 0;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.profile-username-badge {
    display: inline-block;
    font-size: 12px;
    font-weight: 600;
    color: #c13584;
}

.profile-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 14px;
    padding: 10px 8px;
    background: var(--bg-input);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    text-align: center;
}

.stat-box {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.stat-value {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-title);
}

.stat-label {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-sub);
}

.profile-bio-text {
    font-size: 12px;
    color: var(--text-sub);
    line-height: 1.4;
    margin: 10px 0 0 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.profile-action-single {
    margin-top: 14px;
}

.btn-profile-detail {
    width: 100%;
    height: 44px;
    background: var(--primary);
    color: #ffffff;
    font-size: 13.5px;
    font-weight: 700;
    border-radius: var(--radius-sm);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(37, 99, 235, 0.25);
    transition: all 0.15s ease;
}

.btn-profile-detail:hover {
    background: var(--primary-hover);
    color: #ffffff;
}

.btn-profile-detail:active {
    transform: scale(0.98);
}


/* Platform Grid (Mobile App List Style) */
.section-label {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-title);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.platform-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 24px;
}

.platform-row-card {
    background: var(--bg-card);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    cursor: pointer;
    transition: all 0.15s ease;
    position: relative;
}

.platform-row-card:active {
    background: var(--bg-input);
}

.platform-row-card.active {
    border-color: var(--text-title);
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
}

.row-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.row-check {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: var(--text-muted);
    flex-shrink: 0;
    transition: color 0.15s ease;
}

.platform-row-card.active .row-check {
    color: var(--text-title);
}

.row-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    object-fit: contain;
}

.row-text h4 {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-title);
    line-height: 1.2;
    display: flex;
    align-items: center;
    gap: 6px;
}

.row-text p {
    font-size: 11.5px;
    color: var(--text-sub);
    margin-top: 2px;
}

.row-select-type {
    font-size: 12px;
    font-weight: 600;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 5px 8px;
    color: var(--text-body);
    outline: none;
    cursor: pointer;
}

/* 3 Steps Guide */
.steps-box {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 16px;
    margin-bottom: 24px;
}

.step-row {
    display: flex;
    gap: 12px;
    margin-bottom: 14px;
}

.step-row:last-child {
    margin-bottom: 0;
}

.step-badge {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    color: var(--text-title);
    font-size: 11.5px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.step-content h5 {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-title);
    margin-bottom: 2px;
}

.step-content p {
    font-size: 12px;
    color: var(--text-sub);
    line-height: 1.4;
}

/* FAQ Accordion */
.faq-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 24px;
}

.faq-tile {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.faq-head {
    padding: 12px 14px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-title);
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
}

.faq-body {
    display: none;
    padding: 0 14px 12px;
    font-size: 12px;
    color: var(--text-sub);
    line-height: 1.45;
}

.faq-tile.open .faq-body {
    display: block;
}

.faq-tile.open .faq-icon {
    transform: rotate(180deg);
}

/* Toast Alert */
.toast-msg {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(50px);
    background: var(--text-title);
    color: #fff;
    padding: 9px 16px;
    border-radius: var(--radius-full);
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: var(--shadow-float);
    opacity: 0;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100;
    white-space: nowrap;
}

.toast-msg.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* Desktop Adjustments */
@media (min-width: 681px) {
    body {
        padding-bottom: 20px;
    }
    .app-content {
        padding: 24px 16px;
    }
    .hero-headline {
        font-size: 26px;
    }
}
