@import url(default.css);
/* @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap'); */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root{
    --slate-50:#f8fafc;
    --slate-100:#f1f5f9;
    --slate-200:#e2e8f0;
    --slate-600:#475569;
    --slate-800:#1e293b;
    --slate-900:#0f172a;

    --amber-50:#fffbeb;
    --amber-100:#fef3c7;
    --amber-500:#f59e0b;
    --amber-600:#d97706;
    --amber-900:#78350f;

    --emerald-100:#d1fae5;
    --emerald-500:#10b981;

    --red-50:#fef2f2;
    --red-100:#fee2e2;
    --red-500:#ef4444;
    --red-600:#dc2626;
}

body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;    
    min-height: 100vh;   /* fallback */
    min-height: 100dvh;  /* viewport dinâmica */
    min-height: 100svh;  /* “safe” viewport (mais estável) */
    /* font-family: "Lato", sans-serif; */
    font-family:Inter,system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
    font-size: 1.5rem;
    background-color: #f8fafc;
    transition: background-color .4s;

    -webkit-font-smoothing:antialiased;
    -moz-osx-font-smoothing:grayscale;
}

/* body.darkmode {
    background-color: #000;
    color: white;
} */

body:has(.consent),
body.darkmode:has(.consent) {
    background-color: #5071f5;
}


main {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 44.8rem;
    padding: 2rem;
    background-color: #fefefe;
    margin: 2rem;
    border-radius: 2rem;

    border: 1px solid #fff;
    box-shadow: 0 25px 50px -12px rgba(15, 23, 42, .12);
    outline: 1px solid var(--slate-100);
    outline-offset: -1px;
}

main:has(.consent)
{
    max-width: 50rem;
}

nav {
    display: flex;
    flex-direction: row;
    justify-content: flex-end;
}

nav>button,
nav>a {
    border: none;
    background-color: rgba(0,0,0, .03);
    color: black;
    /* margin-right: 1rem; */
    padding: 1rem;            
    border-radius: .5rem;
    cursor: pointer;
}

nav>a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

nav>.btn-login{
  display: flex;
  flex-direction: row;
  align-items:center;
  gap: .8rem;

  padding: .6rem 1.2rem;
  border-radius:99.9rem;

  font-size: 1.2rem;
  font-weight:700;
  color:#64748b;              /* slate-500 */
  text-decoration:none;

  background:rgba(255,255,255,.6);
  backdrop-filter: blur(10px);

  border: .1rem solid rgba(226,232,240,.6); /* slate-200/60 */
  box-shadow: 0 .2rem .6rem rgba(15,23,42,.08);

  transition:
    background-color .2s ease,
    color .2s ease,
    box-shadow .2s ease,
    border-color .2s ease;
}

nav>.btn-login:hover{
  background:#ffffff;
  color:#2563eb;              /* blue-600 */
  border-color:#dbeafe;       /* blue-100 */
  box-shadow:0 .6rem 1.4rem rgba(15,23,42,.12);
}

/* Ícone */
nav>.btn-login .ico-login{
  width: 1.4rem;
  height: 1.4rem;
  stroke:currentColor;

  transition:transform .2s ease;
  user-select:none;
  -webkit-user-select:none;
  -ms-user-select:none;
  pointer-events:none;
}

/* Micro animação no hover */
nav>.btn-login:hover .ico-login{
  transform:translateX(.2rem);
}

/* Acessibilidade */
nav>.btn-login:focus-visible{
  outline: .3rem solid rgba(59,130,246,.35);
  outline-offset: 3rem;
}

nav>* {
    margin-right: 1rem;
}

nav>*:last-child {
    margin-right: 0px;
}

/* nav>button.darkmode,
nav>a.darkmode {
    font-size: 2rem;
}

.darkmode nav>button,
.darkmode nav>a {
    background-color: rgba(255,255,255, .03);
    color: white;
} */


header {
    /* background-color: #F00; */
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 3.2rem;    
}

header>div.picture {
    width: 11.2rem;
    height: 11.2rem;
    background-color: #CECECE;
    border-radius: 999px;
    /* border: 1rem solid #EEE; */
    border: .4rem solid #FFF;
    background-image: url('../images/user-profile.png');
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
    transition: border-color .4s;
    background-size: cover;

    outline: .1rem solid var(--slate-100);
    outline-offset: 0;
    box-shadow: 0 2rem 3rem -1.5rem rgba(15, 23, 42, .18);
}

/* .darkmode header>div.picture {
    border-color: #FFF;
} */

header>h1 {
    margin-top: 3rem;
    font-size: 3.5rem;
    color: #ce1e31;
    font-weight: 600;
}

header .name {
    margin: 0 0 .8rem;
    font-size: 2.4rem;
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -.02em;
    color: var(--slate-900);
    text-align: center;
    margin-top: 2rem;
}

header .blood-badge {
    display: inline-flex;
    align-items: center;
    gap: .8rem;
    background: var(--red-50);
    border: .1rem solid var(--red-100);
    padding: .6rem 1.6rem;
    border-radius: 99.9rem;
    box-shadow: 0 .2rem .8rem rgba(15, 23, 42, .06);
    margin-bottom: 1.6rem;
}

header .icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

header .icon svg {
    width: 1.4rem;
    height: 1.4rem;
}

header .blood-badge .label {
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: rgba(127, 29, 29, .7);
}

header .blood-badge .sep {
    width: .1rem;
    height: 1.2rem;
    background: #fecaca;
    display: inline-block;
}

header .blood-badge .value {
    font-weight: 800;
    color: #dc2626;
}


header .donor-badge{
  background:#faf5ff;        /* purple-50 */
  border-color:#f3e8ff;      /* purple-100 */
}

header .donor-badge .icon svg{
  stroke:#a855f7;            /* purple-500 */
  fill:#f3e8ff;              /* purple-100 */
}

header .donor-badge .label{
  color:rgba(88,28,135,.7);  /* purple-900/70 */
}

header .donor-badge .sep{
  background:#e9d5ff;        /* purple-200 */
}

header .donor-badge .value{
  color:#9333ea;             /* purple-600 */
}


header .info-tags {
    display: flex;
    gap: 1.2rem;
    justify-content: center;
    width: 100%;
}

header .tag .icon.pin svg {
    stroke: #2563eb;
}

header .tag .icon svg {
    width: 12px;
    height: 12px;
}

header .tag {
    display: flex;
    align-items: center;
    gap: .6rem;
    padding: .8rem 1.6rem;
    background: var(--slate-50);
    border: .1rem solid var(--slate-100);
    border-radius: 1.4rem;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--slate-600);
    box-shadow: 0 .2rem .8rem rgba(15, 23, 42, .06);
    white-space: nowrap;
}


header>p {
    margin-top: .5rem;
    font-size: 1.5rem;
    color: #a6a6a6;
}

header>p>i {
    margin-right: 1rem;
}


.cards {
    display: grid;
    gap: 1.2rem;
    margin-bottom: 3.2rem;
}

.cards .card-amber {
    background: rgba(255, 251, 235, .8);
    border: .1rem solid var(--amber-100);
}

.cards .card-blue {
    background: rgba(239, 246, 255, .8);
    border: .1rem solid #dbeafe;
}

.cards .card-slate{
  background: rgba(248,250,252,.9);
  border: 1px solid var(--slate-100);
}


.cards .card-amber .chip svg {
    stroke: var(--amber-500);
}

.cards .card-blue .chip svg {
    stroke: #3b82f6;
}

.cards .card-slate .bg-icon svg{
  stroke: var(--slate-100);
}

.cards .card-amber .bg-icon svg {
    stroke: var(--amber-100);
}

.cards .card .chip svg {
    width: 2rem;
    height: 2rem;
}

.cards .card-slate .chip svg{
  stroke: #64748b;
}

.cards .card {
    position: relative;
    overflow: hidden;
    border-radius: 1.8rem;
    padding: 1.6rem;
    display: flex;
    gap: 1.6rem;
    align-items: center;
    box-shadow: 0 .2rem 1.2rem rgba(15, 23, 42, .06);
    transition: background-color .2s ease, transform .2s ease;
}

.cards .card h3 {
    margin: 0 0 2px;
    font-size: 10px;
    letter-spacing: .18em;
    text-transform: uppercase;
    font-weight: 800;
    opacity: .7;
}

.cards .card-amber h3 {
    color: rgba(120, 53, 15, .6);
}

.cards .card-blue h3 {
    color: rgba(30, 58, 138, .6);
}

.card-slate h3{
  color: rgba(15,23,42,.55);
}

.cards .card p {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--slate-800);
}

.cards .card .bg-icon {
    position: absolute;
    top: -1.6rem;
    right: -1.6rem;
    opacity: .5;
    transition: transform .25s ease;
    pointer-events: none;
}

.cards .card .chip {
    background: #fff;
    padding: 1rem;
    border-radius: 1.4rem;
    box-shadow: 0 .2rem 1rem rgba(15, 23, 42, .08);
    flex: 0 0 auto;
    z-index: 1;
}

.cards .card .meta {
    z-index: 1;
}

section.info {
    background-color: #efefef;
    color: black;
    padding: 2rem;
    border-radius: 2rem;
    width: 100%;
}

section.info div.row {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    margin-bottom: 2rem;    
}

section.info hgroup {
    display: flex;
    flex-direction: column;            
    margin-right: 2rem;
    flex: 1;    
}

section.info hgroup.border {
    flex: 1;
}

section.info hgroup:last-child {
    margin-right: 0;
}

section.info hgroup label {
    font-weight: 400;
}

section.info hgroup:not(.border) label {
    margin-bottom: .5rem;
}

section.info hgroup label i.bi-person-fill,
section.info hgroup label i.bi-people-fill {
    color: #226699;
}

section.info hgroup label i.bi-droplet-fill {
    color: #da2f47;
}

section.info hgroup label i.bi-bicycle {
    color: #ffdc5d;
    text-shadow: 0px 0px 1px #CECECE;            
}

section.info hgroup label i.bi-award-fill {
    color: #50a5e6;
}

section.info hgroup label i.bi-clipboard2-pulse-fill {
    color: #9266cc;
}

.bi-heart-pulse-fill {
    color: #bb1a34;
}

.bi-geo-fill {
    color: #da2f47;
}

div.actions {
    margin-top: auto;
}

.stack {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.btn {
    border: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-radius: 1.8rem;
    width: 100%;
    user-select: none;
}

.btn-tile {
    padding: 1.6rem;
    border-radius: 1.8rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .8rem;
    box-shadow: 0 1.6rem 2.4rem rgba(15, 23, 42, .10);
    transition: transform .05s ease, background-color .2s ease;
}

.btn-primary {
    background: var(--red-500);
    color: #fff;
    padding: 1.6rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 1.6rem 2.4rem rgba(239, 68, 68, .22);
    transition: background-color .2s ease, box-shadow .2s ease, transform .05s ease;
    text-decoration: none;
    gap: 1.6rem;
}

.btn-primary .title {
    font-size: 1.8rem;
    font-weight: 900;
    line-height: 1;
    margin-bottom: .6rem;
}

.btn-primary .subtitle {
    display: inline-block;
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: #fee2e2;
    background: rgba(127, 29, 29, .30);
    padding: .2rem .8rem;
    border-radius: .8rem;
}

.btn-primary .left {
    display: flex;
    align-items: center;
    gap: 1.6rem;
    padding-left: .4rem;
    flex: 1;
}

.btn-primary .left .text {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.shine {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .10), transparent);
    transform: translateX(-100%);
    transition: transform 1s ease;
    pointer-events: none;
}

.btn-primary .iconbox {
    background: rgba(255, 255, 255, .20);
    padding: 1rem;
    border-radius: 1.4rem;
    backdrop-filter: blur(.6rem);
}

.btn-primary .iconbox svg {
    width: 2.4rem;
    height: 2.4rem;
    stroke: #fff;
}

.btn-primary .right {
    padding-right: .8rem;
    opacity: .85;
}

.btn-primary .round {
    width: 3.2rem;
    height: 3.2rem;
    background: rgba(255, 255, 255, .10);
    border-radius: 99.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.2rem;
}

.btn-grid > .btn-tile:only-child{
  grid-column: 1 / -1; /* ocupa as 2 colunas */
}

.btn-primary .round svg {
    width: 1.6rem;
    height: 1.6rem;
    stroke: #fff;
}

.btn-whatsapp {
    background: #22c55e;
    color: #fff;
    box-shadow: 0 1.6rem 2.4rem rgba(34, 197, 94, .18);
    text-decoration: none;
}

.btn-whatsapp svg {
    width: 2.4rem;
    height: 2.4rem;
    stroke: #fff;
}

.btn-label {
    font-size: 1.4rem;
    font-weight: 900;
    letter-spacing: .04em;
}

.btn-location {
    background: var(--slate-800);
    color: #fff;
    box-shadow: 0 1.6rem 2.4rem rgba(15, 23, 42, .12);
    /* position: relative; */
    text-decoration: none;
}

.btn-location svg {
    width: 2.4rem;
    height: 2.4rem;
    stroke: #fff;
}

.animate-zoom-in {
    animation: zoom-in .2s ease-out forwards;
}

.success {
    color: #34d399;
    font-weight: 900;
}

.footer {
    margin-top: 32px;
    text-align: center;
    opacity: .4;
}

.footer p {
    margin: 0;
    font-size: 10px;
    color: #64748b;
}

.brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-bottom: 4px;
}

.brand svg {
    width: 14px;
    height: 14px;
    stroke: var(--slate-900);
}





/* footer {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin-top: 3.2rem;
}

footer p {
    color: #a6a6a6;
    text-align: center;
}

footer div.logo {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;            
}

footer div.logo>.qr-safety {
    width: 13rem;
    height: 3rem;            
    background-image: url('../images/logo-qrsafety-black.png');
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
} */

/* .darkmode footer div.logo>.qr-safety {
    background-image: url('../images/logo-qrsafety-white.png');
} */


footer div.logo>.trakii {
    width: 13rem;
    height: 1.2rem;            
    background-image: url('../images/bytrakii.png');
    background-repeat: no-repeat;
    background-position: right;
    background-size: contain;
    margin-top: .5rem;
}

@media screen and (max-width: 65rem) {

    section.info div.row:nth-child(1) {        
        /* flex-wrap: wrap; */
        flex-direction: column;
    }

    section.info div.row:first-child>hgroup:nth-child(1)
    {
        margin-right: 0;
    }

    section.info div.row:first-child>hgroup:nth-child(2) {
        flex: 0 0 100%;
        margin-right: 0;
        margin-top: 2rem;
    }

    section.actions button {
        padding: 2rem;
        font-size: 1.6rem;        
    }
}



/*
    MENSAGEM DE COMPARTILHAMENTO
*/

/* body:not(.darkmode) section.consent {
    border: 1px solid #d8d8d8;
} */

section.consent {
    /* background-color: #fff; */    
    /* max-width: 50rem; */
    width: 100%;
    text-align: center;
    color: #333;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-family: 'Inter', sans-serif;
    height: auto;
}


section.consent div.card {
    background-color: #FFF;
    border-radius: 3rem;
    /* box-shadow: 0 .4rem .8rem rgba(0, 0, 0, 0.1);     */
    padding: 6rem 4rem;
    max-width: 53rem;
    width: 100%;
}

section.consent .qr-safety-logo {
    max-width: 30rem;
    width: 100%;
    height: 13.16rem;    
    display: inline-block;
    color: #4b6bfb;
    background-color: currentColor;
    -webkit-mask: url("../images/logo.svg") no-repeat center / contain;
    mask: url("../images/logo.svg") no-repeat center / contain;
    user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    pointer-events: none;
}

section.consent h2 {
    font-size: 1.6rem;
    line-height: 1.6;
    margin-bottom: 2rem;
    font-weight: bold;
    color: #959595;
}

section.consent p {
    font-size: 1.6rem;
    line-height: 1.2;
    margin-bottom: 2rem;
    color: #969696;
}

section.consent form {
    display: flex;
    flex-direction: column;    
    gap: 2rem;
    padding: 4rem;
}

section.consent button {
    padding: 2rem 4rem;
    font-size: 1.6rem;
    border: none;
    border-radius: .5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;    
    text-transform: uppercase;
    position: relative;
}

section.consent button[name="accept"] {
    background-color: #4CAF50;
    color: white;
}

section.consent button[name="decline"] {
    background-color: #f44336;
    color: white;
}

section.consent button:not(:disabled):hover {
    opacity: 0.9;
}

section.consent button[name="decline"]:not(:disabled):hover {
    background-color: #d32f2f;
}

section.consent button[name="accept"]:not(:disabled):hover {
    background-color: #45a049;
}

section.consent button:disabled {
    opacity: .8;
    cursor: not-allowed;
}

button.is-loading{
  pointer-events: none;
  opacity: .85;
}

/* Esconde o texto enquanto carrega (opcional) */
button.is-loading .btn-text{
  visibility: hidden;
}

/* Spinner */
button.is-loading::before{
  content: "";
  position: absolute;
  width: 1.1em;
  height: 1.1em;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: btn-spin .7s linear infinite;
  left: 1.5rem;
}

@keyframes btn-spin{
  to { transform: rotate(360deg); }
}

@media (max-width: 600px) {

    main:has(section.consent) {
        
    }

    section.consent div.card
    {
        padding: 2rem;        
    }

    section.consent form {
        flex-direction: column;
        gap: 1rem;
    }

    section.consent button {
        width: 100%;
    }
}