/* =========================================
   1. CORE STYLES & FONTS
   ========================================= */
@import url('https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:wght@400;500;600;700;800&display=swap');

:root {
    --main-color: #5cb85c;
    --main-color-hover: #4cae4c;
    --bg-color: #f8f9fa;
    --text-color: #333;
}

body {
    background-color: var(--bg-color);
    font-family: 'Be Vietnam Pro', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a {
    text-decoration: none;
}

/* =========================================
   2. HEADER & LOGO
   ========================================= */
.main-header {
    text-align: center;
    margin-bottom: 30px;
    padding-top: 40px;
}

.brand-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    text-decoration: none;
    position: relative;
    padding: 10px 20px;
    margin-bottom: 15px;
    overflow: hidden;
}

.brand-logo .logo-icon {
    font-size: 2.5rem;
    color: var(--main-color);
    text-shadow: 0 4px 10px rgba(92, 184, 92, 0.3);
    display: flex;
    align-items: center;
}

.brand-logo .logo-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    line-height: 1;
}

.brand-logo .main-text {
    font-size: 2rem;
    font-weight: 900;
    background: linear-gradient(135deg, #2c3e50 30%, #5cb85c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-transform: uppercase;
    letter-spacing: -0.5px;
}

.brand-logo .sub-text {
    font-size: 0.75rem;
    font-weight: 600;
    color: #888;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-top: 3px;
    margin-left: 2px;
}

.brand-logo::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.6) 50%, rgba(255, 255, 255, 0) 100%);
    transform: skewX(-25deg);
    animation: shine-logo 3.5s infinite;
    pointer-events: none;
}

@keyframes shine-logo {
    0% {
        left: -100%;
        opacity: 0;
    }

    20% {
        opacity: 1;
    }

    40% {
        left: 200%;
        opacity: 0;
    }

    100% {
        left: 200%;
        opacity: 0;
    }
}

@media (max-width: 480px) {
    .brand-logo .main-text {
        font-size: 1.6rem;
    }

    .brand-logo .logo-icon {
        font-size: 2rem;
    }
}

.main-header p {
    color: #666;
    max-width: 600px;
    margin: 0 auto;
    font-size: 15px;
}

/* =========================================
   3. TOOL CARD & FORM
   ========================================= */
.tool-card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    background: #fff;
    overflow: hidden;
    margin-bottom: 30px;
}

.tool-card-header {
    background-color: var(--main-color);
    color: white;
    padding: 15px;
    font-weight: 700;
    text-align: center;
    font-size: 18px;
    text-transform: uppercase;
}

.tool-card-body {
    padding: 30px;
}

.form-label {
    font-weight: 600;
    font-size: 14px;
    color: #555;
}

.form-control,
.form-select {
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    padding: 10px 15px;
    font-size: 15px;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--main-color);
    box-shadow: 0 0 0 0.2rem rgba(92, 184, 92, 0.25);
}

.btn-resolve {
    background-color: var(--main-color);
    color: white;
    font-weight: 700;
    border: none;
    border-radius: 8px;
    padding: 10px;
    transition: all 0.3s ease;
    width: 100%;
}

.btn-resolve:hover {
    background-color: var(--main-color-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(92, 184, 92, 0.3);
}

.btn-loading {
    pointer-events: none;
    opacity: 0.8;
}

.btn-loading .fa-search {
    display: none;
}

.btn-loading::after {
    content: "";
    display: inline-block;
    width: 1rem;
    height: 1rem;
    vertical-align: text-bottom;
    border: .15em solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spinner-border .75s linear infinite;
    margin-left: 5px;
}

@keyframes spinner-border {
    to {
        transform: rotate(360deg);
    }
}

/* =========================================
   4. NEW TRADITIONAL TABLE STYLES (Không dùng trong Pastebin)
   ========================================= */
.result-section {
    margin-top: 30px;
}


/* =========================================
   5. SHARE BOX
   ========================================= */
.share-box-container {
    margin-top: 25px;
    background: #f1fcf5;
    border: 1px dashed var(--main-color);
    border-radius: 8px;
    padding: 15px;
}

.input-group-share .form-control {
    border-color: var(--main-color);
    background: #fff;
    color: var(--main-color);
    font-weight: 500;
}

.btn-copy {
    background-color: var(--main-color);
    color: white;
    border: 1px solid var(--main-color);
    font-weight: 600;
    transition: all 0.3s;
}

.btn-copy:hover {
    background-color: var(--main-color-hover);
    color: white;
}

/* =========================================
   6. FOOTER
   ========================================= */
.site-footer {
    margin-top: auto;
    background: #fff;
    border-top: 1px solid #eee;
    padding: 20px 0;
    text-align: center;
    font-size: 0.9em;
    color: #666;
}

.footer-stats {
    display: inline-flex;
    gap: 20px;
    margin-bottom: 10px;
    background: #f9f9f9;
    padding: 8px 20px;
    border-radius: 50px;
    border: 1px solid #eee;
}

.stat-item i {
    color: var(--main-color);
    margin-right: 5px;
}

.footer-link {
    color: var(--main-color);
    font-weight: 600;
    text-decoration: none;
}

.footer-link:hover {
    text-decoration: underline;
}

/* =========================================
   7. COMMUNITY CARD
   ========================================= */

.join-community-card {
    font-family: 'Be Vietnam Pro', sans-serif;
    width: 100%;
    max-width: 100%;
    margin: 30px auto;
    background: #ffffff;
    border-radius: 16px;
    position: relative;
    border: 2px solid #5cb85c;
    box-shadow: 0 8px 30px -10px rgba(92, 184, 92, 0.15);
    overflow: hidden;
    transition: transform 0.3s ease;
}

.join-community-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px -10px rgba(92, 184, 92, 0.25);
}

.card-content {
    padding: 20px;
    position: relative;
    z-index: 2;
    text-align: center;
}

.card-header-community {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 10px;
}

.icon-pulse {
    width: 36px;
    height: 36px;
    background: #e0f2fe;
    color: #0284c7;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    animation: pulse-blue 2s infinite;
}

@keyframes pulse-blue {
    0% {
        box-shadow: 0 0 0 0 rgba(2, 132, 199, 0.4);
    }

    70% {
        box-shadow: 0 0 0 8px rgba(2, 132, 199, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(2, 132, 199, 0);
    }
}

.join-community-card h4 {
    font-size: 20px;
    margin: 0;
    color: #1e293b;
    font-weight: 800;
}

.card-desc {
    font-size: 14px;
    color: #64748b;
    line-height: 1.5;
    margin: 0 auto 20px;
    max-width: 95%;
}

.community-buttons {
    display: block;
    text-align: center;
    gap: 10px;
    margin-top: 15px;
}

.comm-btn {
    min-width: 160px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 15px;
    border-radius: 10px;
    text-decoration: none;
    color: white;
    font-weight: 600;
    font-size: 13px;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
    box-shadow: 0 3px 5px -1px rgba(0, 0, 0, 0.1);
    margin: 5px;
}

.comm-btn .btn-icon {
    background: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
}

.comm-btn .btn-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.comm-btn span {
    flex: 1;
    text-align: center;
    padding: 0 4px;
}

.arrow-action {
    font-size: 11px;
    opacity: 0.6;
    transition: transform 0.3s;
    margin-left: 8px;
}

.comm-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 12px -3px rgba(0, 0, 0, 0.15);
}

.comm-btn:hover .arrow-action {
    transform: translateX(3px);
    opacity: 1;
}

.comm-btn.fb {
    background: linear-gradient(135deg, #1877f2, #3b82f6);
}

.comm-btn.zalo {
    background: linear-gradient(135deg, #0068ff, #009efd);
}

.comm-btn.telegram {
    background: linear-gradient(135deg, #2aabee, #229ed9);
}

@media (max-width: 600px) {
    .community-buttons {
        display: block;
        padding: 0 10px;
    }

    .comm-btn {
        width: 100%;
        box-sizing: border-box;
        justify-content: flex-start;
        margin-bottom: 10px;
        margin-left: 0;
        margin-right: 0;
    }

    .comm-btn span {
        text-align: left;
        padding-left: 10px;
    }
}


/* =========================================
   8. FIX MOBILE TABLE OVERFLOW (Không dùng trong Pastebin)
   ========================================= */
@media (max-width: 767px) {
    
    .dns-table-wrapper {
        overflow-x: auto;
    }

    .table-new-style {
        min-width: 650px; 
        table-layout: auto; 
    }
    
    .domain-cell-new, 
    .answer-cell-new {
        white-space: normal;
        word-break: break-word;
    }
    
    .table-new-style thead th:nth-child(1), 
    .table-new-style tbody td:nth-child(1) { width: 35% !important; } 
    
    .table-new-style thead th:nth-child(2), 
    .table-new-style tbody td:nth-child(2) { width: 15% !important; } 
    
    .table-new-style thead th:nth-child(3), 
    .table-new-style tbody td:nth-child(3) { width: 15% !important; } 
    
    .table-new-style thead th:nth-child(4), 
    .table-new-style tbody td:nth-child(4) { width: 35% !important; } 
}