/* ==========================================================================
   KONTEN UTAMA (CONTACT LAYOUT)
   ========================================================================== */
   .contact-main-container {
    padding: 60px 20px;
    max-width: 1000px; /* Dikecilkan sedikit dari 1200px supaya kad tidak terlalu lebar & nampak padat */
    margin: 40px auto;
    font-family: 'Inter', sans-serif;
}

.contact-title {
    font-size: 2.2rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-align: center;
    background: white;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
}

.contact-intro {
    text-align: center;
    color: white;
    font-size: 1.05rem;
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    text-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
}

/* GRID CONFIGURATION */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* Tetapkan 2 kolum sekata */
    gap: 32px; /* Jarak antara kad yang lebih selesa */
    align-items: stretch; /* RAHSIA 1: Memaksa semua kad mempunyai tinggi yang SAMA TEPAT */
    margin-bottom: 50px;
}

/* ==========================================================================
   REKA BENTUK KAD (CONTACT ITEM)
   ========================================================================== */
.contact-item {
    background: #ffffff; /* Ditukar ke putih bersih supaya kontras dengan background biru luar */
    border: 1px solid #e2e8f0;
    border-radius: 24px; /* Sudut lebih melengkung modern */
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* RAHSIA 2: Menolak bahagian bottom link ke bawah sejajar */
    align-items: center;
    box-sizing: border-box;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px -1px rgba(0, 0, 0, 0.01);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), border-color 0.3s ease, box-shadow 0.3s ease;
}

/* Efek Hover Premium */
.contact-item:hover {
    transform: translateY(-6px);
    border-color: #db2777;
    box-shadow: 0 20px 25px -5px rgba(219, 39, 119, 0.1), 0 10px 10px -5px rgba(219, 39, 119, 0.04);
}

/* Pembungkus Atas & Bawah */
.contact-content-top {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.contact-content-bottom {
    width: 100%;
    text-align: center;
    margin-top: 32px; /* Jarak standard dari elemen di atasnya */
}

.contact-card-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

/* ==========================================================================
   IKON DAN TEKS UTAMA
   ========================================================================== */
.contact-icon-box {
    width: 64px;
    height: 64px;
    background: #f8fafc;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 16px;
    border: 1px solid #e2e8f0;
    transition: transform 0.3s ease, background-color 0.3s ease, border-color 0.3s ease;
}

.contact-item:hover .contact-icon-box {
    transform: scale(1.05);
    background: #fdf2f8;
    border-color: #fbcfe8;
}

/* Warna Ikon Dinamik */
.contact-icon-box i.fa-envelope { color: #0ea5e9; font-size: 1.5rem; }
.contact-icon-box i.fa-telegram { color: #24a1de; font-size: 1.6rem; }

.contact-item h3 {
    font-size: 1.4rem;
    color: #0f172a;
    margin: 0 0 4px 0;
    font-weight: 700;
}

/* ==========================================================================
   BAHAGIAN KOD QR TELEGRAM
   ========================================================================== */
.qr-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    background: #f8fafc;
    padding: 16px;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    margin-top: 20px;
    width: fit-content;
    transition: border-color 0.3s ease, background-color 0.3s ease;
}

.contact-item:hover .qr-wrapper {
    border-color: #fbcfe8;
    background: #ffffff;
}

.qr-image {
    width: 130px;
    height: 130px;
    object-fit: contain;
    border-radius: 12px;
    display: block;
}

.qr-text {
    font-size: 0.75rem;
    font-weight: 700;
    color: #64748b;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 6px;
}

.contact-item:hover .qr-text {
    color: #db2777;
}

/* ==========================================================================
   PAUTAN TEKS (BOLEH DI-COPY / USER-SELECT)
   ========================================================================== */
.contact-link {
    font-size: 0.95rem;
    color: #475569;
    font-weight: 600;
    word-break: break-all;
    text-decoration: none;
    display: inline-block;
    padding: 8px 16px;
    background: #f1f5f9;
    border-radius: 30px; /* Dibuat bentuk pill supaya nampak seperti button copy yang kemas */
    transition: all 0.3s ease;
    
    /* Fungsi Cepat Highlight untuk Copy */
    cursor: text;
    user-select: all;
    -webkit-user-select: all;
}

.contact-link:hover {
    color: #ffffff;
    background: #db2777; /* Bertukar magenta penuh apabila di-hover */
    box-shadow: 0 4px 12px rgba(219, 39, 119, 0.2);
}

/* ==========================================================================
   FOOTER (CLOSING TEXT)
   ========================================================================== */
.contact-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.4); /* Garis pemisah diserasikan dengan tona background biru */
    margin: 40px 0;
    border: none;
}

.contact-closing {
    text-align: center;
    font-size: 1rem;
    line-height: 1.8;
    color: white;
    max-width: 750px;
    margin: 0 auto;
    font-weight: 500;
}

.contact-closing span {
    color: magenta;
    font-weight: 700;
}

/* BAHARU: Susunan rapat ke tengah untuk kad yang TIADA QR (seperti kad Emel) */
.contact-item.center-layout {
    justify-content: center; /* Rapatkan semua kandungan ke tengah-tengah kad */
    gap: 20px;               /* Mengawal jarak yang sekata dan rapat antara elemen */
}

/* Memastikan tiada margin atas tambahan yang menolak teks ke bawah */
.contact-item.center-layout .contact-content-bottom {
    margin-top: 0; 
}

/* RESPONSIVE (MOBILE OPTIMIZATION) */
@media (max-width: 768px) {
    .contact-grid {
        grid-template-columns: 1fr; /* Jadi 1 kolum sahaja pada skrin phone */
        gap: 20px;
    }
    .contact-item {
        padding: 30px 20px;
    }
    .contact-content-bottom {
        margin-top: 24px;
    }
}