/* DNS Certificates Page - Style like CertVN */

.dns-page {
    background: #0a0a0a;
    min-height: 100vh;
    padding: 100px 0 60px 0;
    font-family: 'Inter', 'Be Vietnam Pro', -apple-system, BlinkMacSystemFont, sans-serif;
}

.dns-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 16px;
}

/* Header */
.dns-header {
    text-align: center;
    margin-bottom: 40px;
}

.dns-header h1 {
    font-size: 2rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.dns-header p {
    color: #a1a1aa;
    font-size: 0.95rem;
    margin-bottom: 6px;
}

.dns-header .subtitle {
    color: #71717a;
    font-size: 0.85rem;
}

/* Step Number */
.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: #27272a;
    color: #a1a1aa;
    border-radius: 50%;
    font-size: 0.85rem;
    font-weight: 700;
    flex-shrink: 0;
}

/* Section */
.dns-section {
    background: #18181b;
    border: 1px solid #27272a;
    border-radius: 16px;
    padding: 28px;
    margin-bottom: 20px;
}

.dns-section h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 12px;
}

.step-title {
    flex: 1 1 auto;
    min-width: 0;
}

.required-badge {
    background: #dc2626;
    color: white;
    font-size: 0.7rem;
    padding: 3px 10px;
    border-radius: 6px;
    font-weight: 600;
    letter-spacing: 0.5px;
    white-space: nowrap;
    flex-shrink: 0;
}

.dns-section .desc {
    color: #a1a1aa;
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 20px;
}

/* Install DNS Button */
.install-dns-btn {
    background: #3b82f6;
    color: #ffffff !important;
    border: none;
    padding: 12px 28px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease;
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    -webkit-font-smoothing: antialiased;
}

.install-dns-btn:hover {
    background: #2563eb;
    color: #ffffff !important;
    text-decoration: none !important;
}

.install-dns-btn:active {
    background: #1d4ed8;
}

/* ESign selector */
.app-selector {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 24px;
    padding: 12px 16px;
    background: #27272a;
    border-radius: 12px;
}

.app-selector-label {
    color: #a1a1aa;
    font-size: 0.85rem;
    font-weight: 500;
}

.app-selector-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.15s ease;
    color: #ffffff !important;
    text-decoration: none !important;
}

.app-selector-tab.active {
    background: #3b82f6;
    color: #ffffff !important;
}

.app-selector-tab:not(.active) {
    background: transparent;
    color: #71717a !important;
}

.app-selector-tab:not(.active):hover {
    background: #3f3f46;
    color: #ffffff !important;
}

.app-selector-tab img {
    width: 20px;
    height: 20px;
    border-radius: 4px;
}

/* Search */
.dns-search {
    margin-bottom: 20px;
}

.dns-search input {
    width: 100%;
    padding: 12px 16px;
    background: #27272a;
    border: 1px solid #3f3f46;
    border-radius: 12px;
    font-size: 0.95rem;
    color: #ffffff;
    transition: border-color 0.15s ease;
    -webkit-font-smoothing: antialiased;
    box-sizing: border-box;
}

.dns-search input::placeholder {
    color: #71717a;
}

.dns-search input:focus {
    outline: none;
    border-color: #3b82f6;
}

/* Cards Grid */
.dns-apps-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Card */
.dns-app-card {
    background: #1c1c1f;
    border: 1px solid #27272a;
    border-radius: 14px;
    padding: 20px;
    transition: border-color 0.15s ease;
}

.dns-app-card:hover {
    border-color: #3f3f46;
}

.app-name {
    font-size: 1.05rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 12px;
    line-height: 1.4;
}

/* Card buttons row */
.card-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* Download Certificate button (green) */
.download-btn {
    background: #22c55e;
    color: #ffffff !important;
    border: none;
    padding: 10px 18px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background 0.15s ease;
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    -webkit-font-smoothing: antialiased;
    white-space: nowrap;
}

.download-btn:hover {
    background: #16a34a;
    color: #ffffff !important;
    text-decoration: none !important;
}

.download-btn:active {
    background: #15803d;
}

/* Card meta (date, views) */
.card-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #71717a;
    font-size: 0.8rem;
}

.card-meta i {
    font-size: 0.75rem;
}

.meta-separator {
    width: 4px;
    height: 4px;
    background: #3f3f46;
    border-radius: 50%;
}

.view-count {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* Install Now button */
.install-now-btn {
    background: #3b82f6;
    color: #ffffff !important;
    border: none;
    padding: 10px 18px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background 0.15s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none !important;
    -webkit-font-smoothing: antialiased;
    margin-left: auto;
    white-space: nowrap;
}

.install-now-btn:hover {
    background: #2563eb;
    color: #ffffff !important;
    text-decoration: none !important;
}

.install-now-btn:active {
    background: #1d4ed8;
}

.esign-icon {
    width: 20px;
    height: 20px;
    border-radius: 4px;
}

/* No results */
.no-results {
    text-align: center;
    padding: 50px 20px;
    color: #71717a;
}

.no-results i {
    font-size: 3rem;
    margin-bottom: 15px;
    opacity: 0.3;
}

.no-results h3 {
    color: #a1a1aa;
}

/* Footer */
.dns-footer {
    text-align: center;
    padding: 30px 0;
    color: #71717a;
    font-size: 0.9rem;
}

.dns-footer a {
    color: #3b82f6 !important;
    font-weight: 600;
    text-decoration: none !important;
}

.dns-footer a:hover {
    color: #60a5fa !important;
    text-decoration: underline !important;
}

/* Guide button */
.guide-btn {
    background: transparent;
    color: #a1a1aa;
    border: 1px solid #3f3f46;
    padding: 8px 20px;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
    -webkit-font-smoothing: antialiased;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.guide-btn:hover {
    background: #27272a;
    color: #ffffff;
    border-color: #52525b;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .dns-page {
        padding: 80px 0 40px 0;
    }
    
    .dns-container {
        padding: 0 12px;
    }
    
    .dns-header h1 {
        font-size: 1.5rem;
    }
    
    .dns-section {
        padding: 20px;
        border-radius: 12px;
    }
    
    .dns-section h2 {
        font-size: 1.05rem;
        gap: 6px 10px;
    }
    
    .step-title {
        flex-basis: calc(100% - 44px);
    }
    
    .required-badge {
        margin-left: 38px;
        margin-top: -4px;
    }
    
    .dns-app-card {
        padding: 16px;
    }
    
    .card-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .install-now-btn {
        margin-left: 0;
        justify-content: center;
    }
    
    .download-btn {
        justify-content: center;
    }
    
    .install-dns-btn {
        width: 100%;
        justify-content: center;
    }
    
    .app-selector {
        flex-wrap: wrap;
        gap: 8px;
    }
}

@media (max-width: 400px) {
    .dns-header h1 {
        font-size: 1.3rem;
    }
    
    .dns-section {
        padding: 16px;
    }
    
    .dns-app-card {
        padding: 14px;
    }
}
