css
/* =========================================================
   ICE PedidoGo v1.0 - SR. GEEK
   Diseño Premium - Apple + Material Design
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&display=swap');


:root{
    --primary:#C1121F;
    --primary-dark:#8B0000;
    --secondary:#111827;
    --success:#16A34A;
    --whatsapp:#25D366;
    --warning:#F59E0B;
    --danger:#DC2626;
    --info:#2563EB;
    --background:#F4F6F8;
    --card:#FFFFFF;
    --text:#1F2937;
    --muted:#6B7280;
    --border:#E5E7EB;
    --shadow:0 10px 25px rgba(0,0,0,.08);
    --radius:22px;
}


/* =========================================================
   RESET
========================================================= */

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
    font-family:'Poppins',sans-serif;
}


html{
    scroll-behavior:smooth;
}


body{
    background:var(--background);
    color:var(--text);
    min-height:100vh;
    padding-bottom:95px;
}


a{
    text-decoration:none;
    color:inherit;
}


img{
    max-width:100%;
    display:block;
}


/* =========================================================
   HERO
========================================================= */

.hero{
    background:linear-gradient(
        135deg,
        var(--primary-dark),
        var(--primary)
    );

    color:white;

    /* REDUCIDO PARA EVITAR ENCIMADO */
    padding:40px 20px 55px;

    border-radius:0 0 28px 28px;

    position:relative;
    overflow:hidden;
}


.hero::before{
    content:"";

    position:absolute;

    width:220px;
    height:220px;

    background:rgba(255,255,255,.05);

    border-radius:50%;

    top:-90px;
    right:-70px;

    pointer-events:none;
}


.hero::after{
    content:"";

    position:absolute;

    width:150px;
    height:150px;

    background:rgba(255,255,255,.04);

    border-radius:50%;

    bottom:-60px;
    left:-40px;

    pointer-events:none;
}


.logo-circle{
    width:85px;
    height:85px;

    background:white;
    color:var(--primary);

    border-radius:50%;

    display:flex;
    align-items:center;
    justify-content:center;

    font-size:36px;

    margin:auto;

    box-shadow:
        0 8px 18px rgba(0,0,0,.20);
}


.hero h1{
    font-size:32px;

    margin-top:15px;

    font-weight:800;

    line-height:1.3;
}


.hero p{
    opacity:.95;

    margin-top:8px;

    font-size:15px;

    line-height:1.5;
}


/* =========================================================
   CONTENEDOR
========================================================= */

.container{
    width:min(1100px,92%);
    margin:auto;
}


.section{

    /* ANTES: -45px
       AHORA SE EVITA EL ENCIMADO */

    margin-top:-15px;

    margin-bottom:40px;

    position:relative;

    z-index:2;
}


.card{
    background:var(--card);

    border-radius:var(--radius);

    box-shadow:var(--shadow);

    padding:25px;

    margin-bottom:25px;
}


.card-title{
    font-size:24px;

    font-weight:700;

    margin-bottom:18px;

    color:var(--secondary);

    line-height:1.35;
}


.subtitle{
    color:var(--muted);

    font-size:14px;

    margin-bottom:20px;

    line-height:1.6;
}


/* =========================================================
   BOTONES
========================================================= */

.btn{
    display:flex;

    align-items:center;
    justify-content:center;

    gap:10px;

    width:100%;

    padding:16px;

    border-radius:18px;

    font-weight:600;

    border:none;

    cursor:pointer;

    transition:.25s;

    font-size:16px;

    line-height:1.3;
}


.btn:hover{
    transform:translateY(-2px);

    box-shadow:
        0 8px 20px rgba(0,0,0,.15);
}


.btn-primary{
    background:var(--primary);
    color:white;
}


.btn-success{
    background:var(--success);
    color:white;
}


.btn-dark{
    background:var(--secondary);
    color:white;
}


.btn-whatsapp{
    background:var(--whatsapp);
    color:white;
}


.btn-warning{
    background:var(--warning);
    color:white;
}


.btn-outline{
    background:white;

    border:2px solid var(--primary);

    color:var(--primary);
}


/* =========================================================
   GRID
========================================================= */

.grid{
    display:grid;

    grid-template-columns:
        repeat(auto-fit,minmax(220px,1fr));

    gap:18px;
}


.info-box{
    background:#fafafa;

    border:1px solid var(--border);

    border-radius:18px;

    padding:22px;

    text-align:center;
}


.info-box span{
    font-size:13px;

    color:var(--muted);
}


.info-box h2{
    margin-top:8px;

    color:var(--primary);

    font-size:30px;

    line-height:1.3;
}


/* =========================================================
   FEATURES
========================================================= */

.feature{
    text-align:center;

    padding:20px;
}


.feature-icon{
    width:70px;
    height:70px;

    background:
        linear-gradient(
            135deg,
            #ffe6e8,
            #ffd4d8
        );

    color:var(--primary);

    border-radius:20px;

    display:flex;

    align-items:center;
    justify-content:center;

    font-size:32px;

    margin:auto auto 15px;
}


.feature h3{
    font-size:18px;

    margin-bottom:8px;
}


.feature p{
    color:var(--muted);

    font-size:14px;

    line-height:1.5;
}


/* =========================================================
   PERFIL
========================================================= */

.profile-header{
    text-align:center;
}


.avatar{
    width:115px;
    height:115px;

    border-radius:50%;

    object-fit:cover;

    border:5px solid white;

    box-shadow:
        0 5px 20px rgba(0,0,0,.15);

    margin:auto;
}


.profile-name{
    font-size:30px;

    font-weight:700;

    margin-top:12px;

    line-height:1.3;
}


.badges{
    display:flex;

    justify-content:center;

    flex-wrap:wrap;

    gap:8px;

    margin-top:12px;
}


.badge{
    padding:9px 14px;

    border-radius:999px;

    font-size:14px;

    font-weight:600;

    color:white;

    line-height:1.3;
}


.badge-red{
    background:var(--danger);
}


.badge-yellow{
    background:var(--warning);
}


.badge-blue{
    background:var(--info);
}


.badge-green{
    background:var(--success);
}


/* =========================================================
   🚨 TARJETA DE EMERGENCIA
========================================================= */

.emergency-card{

    background:#fff5f5;

    border:2px solid #fecaca;

    border-radius:18px;

    padding:18px 16px;

    margin-top:0;

    margin-bottom:22px;

    text-align:center;

    line-height:1.5;

    overflow:hidden;

    position:relative;

    z-index:3;
}


.emergency-card h2{

    display:block;

    width:100%;

    margin:0 0 8px 0 !important;

    padding:0 !important;

    color:#b91c1c;

    font-size:20px;

    font-weight:800;

    line-height:1.35 !important;

    height:auto !important;

    min-height:0 !important;
}


.emergency-card p{

    display:block;

    width:100%;

    margin:0 !important;

    padding:0 !important;

    color:#7f1d1d;

    font-size:14px;

    font-weight:500;

    line-height:1.5 !important;

    height:auto !important;

    min-height:0 !important;
}


/* =========================================================
   ALERTA MÉDICA
========================================================= */

.medical-alert{

    background:#fff4f4;

    border-left:6px solid var(--danger);

    padding:18px;

    border-radius:16px;

    margin-top:0;

    margin-bottom:20px;

    line-height:1.6;
}


.medical-alert h3{

    color:var(--danger);

    margin-bottom:8px;

    line-height:1.4;
}


.medical-alert p{

    line-height:1.6;

    margin:0;
}


/* =========================================================
   TARJETAS MÉDICAS
========================================================= */

.medical-grid{

    display:grid;

    grid-template-columns:
        repeat(auto-fit,minmax(180px,1fr));

    gap:15px;

    margin-top:20px;
}


.med-card{

    background:white;

    border-radius:18px;

    padding:18px;

    text-align:center;

    border:1px solid var(--border);

    overflow-wrap:anywhere;
}


.med-card h4{

    color:var(--muted);

    font-size:13px;

    margin-bottom:10px;

    line-height:1.4;
}


.med-card p{

    font-weight:700;

    font-size:20px;

    color:var(--secondary);

    line-height:1.5;

    overflow-wrap:anywhere;
}


.med-card.red p{
    color:var(--danger);
}


.med-card.green p{
    color:var(--success);
}


.med-card.blue p{
    color:var(--info);
}


/* =========================================================
   CONTACTOS
========================================================= */

.contact-card{

    background:white;

    border-radius:20px;

    padding:22px;

    box-shadow:var(--shadow);

    margin-top:18px;

    border-left:6px solid var(--primary);
}


.contact-top{

    display:flex;

    justify-content:space-between;

    align-items:center;

    margin-bottom:15px;
}


.contact-name{

    font-size:20px;

    font-weight:700;

    line-height:1.4;
}


.contact-relation{

    color:var(--muted);

    font-size:14px;

    line-height:1.5;

    margin-top:3px;
}


.contact-phone{

    font-size:18px;

    font-weight:600;

    color:var(--secondary);

    margin-bottom:18px;

    line-height:1.5;
}


.contact-actions{

    display:grid;

    grid-template-columns:1fr 1fr;

    gap:12px;
}


/* =========================================================
   INFORMACIÓN DE UBICACIÓN
========================================================= */

.location-card{

    text-align:center;
}


.location-card .card-title{

    margin-bottom:10px;
}


.location-button{

    width:100%;

    min-height:56px;

    border:0;

    border-radius:16px;

    font-size:17px;

    font-weight:700;

    cursor:pointer;

    background:var(--info);

    color:#fff;

    box-shadow:
        0 5px 15px rgba(37,99,235,.25);

    transition:.25s;

    padding:14px 18px;

    line-height:1.4;
}


.location-button:hover{

    transform:translateY(-2px);

    box-shadow:
        0 8px 20px rgba(37,99,235,.25);
}


.location-button:disabled{

    opacity:.65;

    cursor:wait;

    transform:none;
}


.location-status{

    margin-top:12px;

    font-size:14px;

    line-height:1.5;
}


.whatsapp-location{

    display:inline-flex;

    align-items:center;

    justify-content:center;

    width:100%;

    min-height:52px;

    margin-top:12px;

    border-radius:15px;

    background:var(--whatsapp);

    color:white;

    text-decoration:none;

    font-weight:700;

    padding:14px;

    line-height:1.4;
}


.hidden{

    display:none !important;
}


/* =========================================================
   🚑 BOTÓN 911
========================================================= */

.ice-911{

    position:fixed;

    left:12px;
    right:12px;

    bottom:12px;

    z-index:9999;

    display:flex;

    align-items:center;
    justify-content:center;

    gap:10px;

    min-height:64px;

    background:#dc2626;

    color:#fff;

    border-radius:18px;

    text-decoration:none;

    font-size:21px;

    font-weight:800;

    line-height:1.2;

    box-shadow:
        0 8px 25px rgba(0,0,0,.30);

    border:3px solid #fff;

    transition:.2s;
}


.ice-911:hover{

    transform:translateY(-2px);

    box-shadow:
        0 10px 28px rgba(0,0,0,.35);
}


.ice-911:active{

    transform:scale(.98);
}


/* =========================================================
   FORMULARIOS
========================================================= */

.form-group{

    margin-bottom:18px;
}


.form-group label{

    display:block;

    font-weight:600;

    margin-bottom:8px;
}


.input,
textarea,
select{

    width:100%;

    padding:14px 16px;

    border-radius:16px;

    border:2px solid var(--border);

    background:white;

    outline:none;

    transition:.25s;

    font-size:15px;
}


.input:focus,
textarea:focus,
select:focus{

    border-color:var(--primary);

    box-shadow:
        0 0 0 4px rgba(193,18,31,.12);
}


textarea{

    resize:vertical;

    min-height:110px;
}


/* =========================================================
   LOGIN
========================================================= */

.login-box{

    max-width:450px;

    margin:50px auto;
}


.pin-input{

    text-align:center;

    letter-spacing:10px;

    font-size:28px;

    font-weight:700;
}


/* =========================================================
   ESTADO
========================================================= */

.status-success,
.status-error,
.status-warning{

    padding:14px 18px;

    border-radius:14px;

    margin:15px 0;

    font-weight:600;

    line-height:1.5;
}


.status-success{

    background:#dcfce7;

    color:#166534;
}


.status-error{

    background:#fee2e2;

    color:#991b1b;
}


.status-warning{

    background:#FEF3C7;

    color:#92400E;
}


/* =========================================================
   FOOTER
========================================================= */

footer{

    margin:50px 0 25px;

    text-align:center;

    color:var(--muted);

    font-size:14px;

    line-height:1.5;
}


/* =========================================================
   LOADER
========================================================= */

.loader{

    width:55px;

    height:55px;

    border-radius:50%;

    border:5px solid #eee;

    border-top-color:var(--primary);

    animation:spin 1s linear infinite;

    margin:auto;
}


@keyframes spin{

    to{
        transform:rotate(360deg);
    }

}


.fade-up{

    animation:fadeUp .6s ease;
}


@keyframes fadeUp{

    from{

        opacity:0;

        transform:translateY(25px);
    }

    to{

        opacity:1;

        transform:none;
    }

}


/* =========================================================
   RESPONSIVE
========================================================= */

@media(max-width:768px){

    .hero{

        padding:32px 18px 45px;

        border-radius:0 0 25px 25px;
    }


    .hero h1{

        font-size:27px;

        line-height:1.3;
    }


    .hero p{

        line-height:1.5;
    }


    .logo-circle{

        width:78px;
        height:78px;

        font-size:32px;
    }


    .card{

        padding:20px;
    }


    .section{

        margin-top:-10px;
    }


    .profile-name{

        font-size:24px;

        line-height:1.3;
    }


    .avatar{

        width:105px;
        height:105px;
    }


    .badges{

        gap:7px;

        margin-top:10px;
    }


    .badge{

        padding:8px 12px;

        font-size:13px;
    }


    .contact-actions{

        grid-template-columns:1fr;
    }


    .info-box h2{

        font-size:26px;
    }


    .btn{

        padding:15px;
    }


    .emergency-card{

        padding:17px 14px;

        margin-bottom:20px;
    }


    .emergency-card h2{

        font-size:19px;

        margin-bottom:8px !important;
    }


    .emergency-card p{

        font-size:13.5px;

        line-height:1.5 !important;
    }


    .ice-911{

        left:10px;

        right:10px;

        bottom:10px;

        min-height:62px;

        font-size:19px;

        border-radius:16px;
    }

}


/* =========================================================
   MODO OSCURO
========================================================= */

@media(prefers-color-scheme:dark){

    body{

        background:#0F172A;

        color:#F8FAFC;
    }


    .card,
    .contact-card,
    .med-card,
    .info-box{

        background:#111827;

        border-color:#374151;
    }


    .input,
    textarea,
    select{

        background:#1F2937;

        border-color:#374151;

        color:white;
    }


    .subtitle,
    .contact-relation,
    .info-box span,
    footer{

        color:#CBD5E1;
    }


    .card-title{

        color:#F8FAFC;
    }


    .contact-phone{

        color:#F8FAFC;
    }


    .emergency-card{

        background:#3b1114;

        border-color:#7f1d1d;
    }


    .emergency-card h2{

        color:#fca5a5;
    }


    .emergency-card p{

        color:#fecaca;
    }


    .medical-alert{

        background:#3b1114;
    }


    .med-card p{

        color:#F8FAFC;
    }

}
