@import url('https://fonts.googleapis.com/css?family=Lato:300,400,700&display=swap');

* {
    box-sizing: border-box;
}

body {
    font-family: 'Lato', sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    margin: 0;
    background-color: #f8f9fa;
    padding: 2rem;
}

.parent {
    margin-bottom: 4rem;
    text-align: center;
}

.parent img {
    max-height: 25vh;
    width: auto;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
}

.subsidiaries {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.subsidiaries .subBox {
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
    border: none;
    position: relative;
    height: 280px;
}

.subsidiaries .subBox:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.content {
    position: relative;
    height: 100%;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}

.subBox img {
    max-width: 150px;
    height: auto;
    transition: transform 0.3s ease;
}

.description {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    padding: 1.5rem;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.subBox:hover .description,
.subBox:focus-within .description {
    transform: translateY(0);
}

.subBox:hover img,
.subBox:focus-within img {
    transform: translateY(-10px);
}

.description h3 {
    margin: 0 0 0.5rem 0;
    color: #2c3e50;
    font-weight: 700;
}

.description p {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.5;
    color: #666;
    font-weight: 300;
}

@media (max-width: 768px) {
    body {
        padding: 1rem;
    }
    
    .subsidiaries {
        grid-template-columns: 1fr;
    }
    
    .parent {
        margin-bottom: 2rem;
    }
    
    .subBox img {
        max-width: 120px;
    }
    
    /* For touch devices */
    .description {
        transform: translateY(100%);
    }
    
    .subBox:active .description {
        transform: translateY(0);
    }
}

/* Ensure the hover effect works properly on touch devices */
@media (hover: none) {
    .description {
        transform: translateY(100%);
    }
    
    .subBox:active .description {
        transform: translateY(0);
    }
}
/* ==== Dynamic Deep Glossy Theme & Loader (appended) ==== */

:root {
    --gold-1: #ffd56b;
    --gold-2: #f1c40f;
    --gold-3: #a07000;
    --ink-1: #0b0f17;
    --ink-2: #0a0e1a;
    --ink-3: #090a10;
}

body {
    background:
        radial-gradient(1200px 600px at 120% -10%, rgba(255, 213, 107, 0.14), transparent 60%),
        radial-gradient(800px 500px at -20% 120%, rgba(241, 196, 15, 0.08), transparent 60%),
        linear-gradient(135deg, var(--ink-1) 0%, var(--ink-2) 45%, var(--ink-3) 100%);
    color: #eaeaea;
    position: relative;
    overflow-x: hidden;
}

/* Moving glossy sheen overlay */
body::before {
    content: "";
    position: fixed;
    inset: -10% -10% -10% -10%;
    background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.06) 50%, transparent 70%);
    mix-blend-mode: screen;
    pointer-events: none;
    animation: sweep 12s linear infinite;
}

@keyframes sweep {
    0% { transform: translateX(-15%) translateY(-10%) rotate(0.001deg); }
    50% { transform: translateX(15%) translateY(10%) rotate(0.001deg); }
    100% { transform: translateX(-15%) translateY(-10%) rotate(0.001deg); }
}

/* Headline tint for dark bg */
.parent h1 { color: var(--gold-1); letter-spacing: 0.5px; }

/* Page reveal */
.page { opacity: 0; transition: opacity .6s ease .2s; }
.page.show { opacity: 1; }

/* Loader overlay */
.loader {
    position: fixed;
    inset: 0;
    display: grid;
    place-items: center;
    background:
        radial-gradient(60% 60% at 50% 40%, rgba(255, 215, 107, 0.06), rgba(0,0,0,0) 70%),
        #05060a;
    z-index: 9999;
    transition: opacity .6s ease, visibility 0s linear .6s;
}
.loader.hide { opacity: 0; visibility: hidden; }

.coin-wrap { filter: drop-shadow(0 20px 30px rgba(0,0,0,.6)) drop-shadow(0 0 70px rgba(255,213,107,.18)); }

.coin { width: 180px; height: 180px; animation: coinSpin 2.8s cubic-bezier(.4,.1,.2,1) infinite; transform-origin: 50% 50%; }

@keyframes coinSpin {
    0%   { transform: rotateZ(0deg) rotateY(0deg); }
    50%  { transform: rotateZ(180deg) rotateY(180deg); }
    100% { transform: rotateZ(360deg) rotateY(360deg); }
}

/* Respect user prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
    body::before { animation: none; }
    .coin { animation: none; }
    .page { transition: none; }
    .loader { transition: none; }
}

/* Slightly darker cards on dark background */
.subsidiaries .subBox { background: rgba(255,255,255,0.9); }
