*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;font-family:Arial,sans-serif;background:#0b0b0b;color:#f5f1e8;line-height:1.6}a{text-decoration:none;color:inherit}img{max-width:100%;display:block}
:root{--bg:#0b0b0b;--panel:#141414;--panel-2:#1a1a1a;--text:#f5f1e8;--muted:#c8bfae;--red:#b11f1f;--red-hover:#d02a2a;--border:#2b2b2b}
.container{width:min(1180px,92%);margin:auto}
.site-header{position:sticky;top:0;z-index:999;background:rgba(10,10,10,.92);backdrop-filter:blur(10px);border-bottom:1px solid var(--border)}
.nav-wrap{display:flex;align-items:center;justify-content:space-between;min-height:74px}
.brand{display:flex;gap:10px;align-items:center;font-weight:700;letter-spacing:.06em}.brand-logo{width:46px;height:46px;object-fit:cover;border-radius:10px;border:1px solid var(--border);background:#111}
.brand-mark{color:#fff;background:var(--red);padding:10px 12px;border-radius:10px}
.brand-text{color:var(--muted)}
.main-nav{display:flex;gap:22px;align-items:center}
.main-nav a{color:#ddd}
.main-nav a.active,.main-nav a:hover{color:#fff}
.nav-admin{padding:10px 16px;border:1px solid var(--red);border-radius:999px}
.nav-toggle{display:none;background:none;border:none;color:#fff;font-size:28px}
.hero{position:relative;min-height:78vh;display:grid;place-items:center;background-size:cover;background-position:center}
.hero::after{content:'';position:absolute;inset:0;background:linear-gradient(90deg,rgba(0,0,0,.80),rgba(0,0,0,.45),rgba(0,0,0,.55))}
.hero-content{position:relative;z-index:1;width:min(1180px,92%);display:grid;grid-template-columns:1.3fr .7fr;gap:50px;align-items:end;padding:90px 0}
.eyebrow{display:inline-block;padding:10px 14px;border:1px solid rgba(255,255,255,.18);border-radius:999px;color:var(--muted);margin-bottom:14px;background:rgba(255,255,255,.04)}
.hero h1{font-size:clamp(2.2rem,5vw,4.8rem);line-height:1.05;margin:0 0 18px}
.hero p{font-size:1.08rem;color:#e2dbcf;max-width:680px}
.cta-row{display:flex;gap:14px;flex-wrap:wrap;margin-top:28px}
.btn{display:inline-flex;align-items:center;justify-content:center;padding:14px 24px;border-radius:999px;font-weight:700;border:1px solid transparent;transition:.25s}
.btn-primary{background:var(--red);color:#fff}.btn-primary:hover{background:var(--red-hover)}
.btn-secondary{border-color:#fff;color:#fff;background:transparent}.btn-secondary:hover{background:#fff;color:#111}
.hero-card{position:relative;z-index:1;background:rgba(20,20,20,.68);border:1px solid rgba(255,255,255,.1);padding:28px;border-radius:22px}
.hero-card h3{margin-top:0}.hero-stats{display:grid;grid-template-columns:repeat(2,1fr);gap:16px;margin-top:20px}.stat{padding:16px;border-radius:16px;background:rgba(255,255,255,.05);border:1px solid rgba(255,255,255,.06)}.stat strong{display:block;font-size:1.4rem}
section{padding:80px 0}.section-head{max-width:700px;margin-bottom:34px}.section-head h2{font-size:clamp(1.8rem,4vw,3rem);margin:.2rem 0 1rem}.section-head p{color:var(--muted)}
.grid-2{display:grid;grid-template-columns:1fr 1fr;gap:34px;align-items:center}
.story-card,.service-card,.video-card,.testimonial-card,.blog-card,.contact-card,.filter-btn,.process-step,.partner-card,.gallery-card{background:var(--panel);border:1px solid var(--border);border-radius:22px}
.story-card{padding:28px}.story-card p{color:var(--muted)}
.feature-list{display:grid;gap:14px;margin-top:18px}.feature-item{padding:16px 18px;background:var(--panel-2);border:1px solid var(--border);border-radius:18px}
.services-grid,.videos-grid,.testimonials-grid,.blog-grid,.process-grid,.gallery-grid,.partners-grid{display:grid;gap:22px}
.services-grid{grid-template-columns:repeat(3,1fr)}.process-grid{grid-template-columns:repeat(4,1fr)}.gallery-grid{grid-template-columns:repeat(3,1fr)}.videos-grid,.testimonials-grid,.blog-grid,.partners-grid{grid-template-columns:repeat(3,1fr)}
.service-card,.video-card,.testimonial-card,.blog-card,.partner-card{overflow:hidden}
.service-card img,.video-card img,.gallery-card img{height:260px;width:100%;object-fit:cover}
.service-card .content,.video-card .content,.testimonial-card .content,.blog-card .content,.partner-card .content{padding:22px}
.tag{display:inline-block;padding:8px 12px;border-radius:999px;background:rgba(177,31,31,.12);color:#ffb7b7;border:1px solid rgba(177,31,31,.4);font-size:.9rem}
.service-card h3,.video-card h3,.blog-card h3{margin:14px 0 10px}.muted{color:var(--muted)}
.link-arrow{display:inline-flex;align-items:center;gap:8px;color:#fff;margin-top:14px}
.process-step{padding:26px}.process-step span{display:inline-flex;width:42px;height:42px;border-radius:50%;align-items:center;justify-content:center;background:var(--red);font-weight:700}
.gallery-filters{display:flex;flex-wrap:wrap;gap:12px;margin-bottom:24px}
.filter-btn{padding:12px 18px;cursor:pointer}.filter-btn.active,.filter-btn:hover{border-color:var(--red);background:#181010}
.gallery-card{overflow:hidden;position:relative}.gallery-card img{height:320px;object-fit:cover;width:100%}.gallery-card .overlay{position:absolute;inset:auto 0 0 0;padding:18px;background:linear-gradient(180deg,transparent,rgba(0,0,0,.8))}
.testimonial-top{display:flex;gap:14px;align-items:center}.avatar{width:64px;height:64px;border-radius:50%;object-fit:cover;background:#222}.stars{color:#ffd87a}
.partner-card{display:grid;place-items:center;padding:24px;min-height:140px}.partner-card img{max-height:56px;opacity:.9}
.contact-grid{display:grid;grid-template-columns:1fr 1fr;gap:24px}.contact-card{padding:28px}.contact-form input,.contact-form textarea,.contact-form select{width:100%;padding:14px 16px;border-radius:14px;border:1px solid var(--border);background:#101010;color:#fff;margin-bottom:14px}.contact-form textarea{min-height:140px;resize:vertical}
.site-footer{border-top:1px solid var(--border);padding-top:60px;background:#090909}.footer-grid{display:grid;grid-template-columns:1.2fr 1fr 1fr 1fr;gap:28px}.footer-links{list-style:none;padding:0;margin:0;display:grid;gap:10px}.footer-links a{color:var(--muted)}.footer-links a:hover{color:#fff}.footer-bottom{padding:24px 0;color:#999}
.page-hero{padding:90px 0 50px;background:linear-gradient(180deg,#120d0d,#0b0b0b)}.page-hero h1{font-size:clamp(2rem,4vw,3.6rem);margin:0}.page-hero p{color:var(--muted);max-width:700px}
.notice{padding:14px 18px;border-radius:16px;background:#0f1b0f;border:1px solid #1f3f1f;color:#cfeccf;margin-bottom:14px}
.admin-shell{display:grid;grid-template-columns:260px 1fr;min-height:100vh}.admin-side{background:#0f0f0f;border-right:1px solid var(--border);padding:28px 18px}.admin-brand{font-weight:700;font-size:1.4rem;margin-bottom:24px}.admin-menu{display:grid;gap:8px}.admin-menu a{padding:12px 14px;border-radius:14px;color:#ddd}.admin-menu a:hover,.admin-menu a.active{background:#1a1212;border:1px solid #3a1f1f;color:#fff}
.admin-main{padding:28px}.admin-cards{display:grid;grid-template-columns:repeat(4,1fr);gap:18px}.admin-card{background:var(--panel);border:1px solid var(--border);padding:20px;border-radius:18px}.admin-table-wrap{margin-top:22px;background:var(--panel);border:1px solid var(--border);border-radius:18px;overflow:auto}.admin-table{width:100%;border-collapse:collapse}.admin-table th,.admin-table td{padding:14px 16px;border-bottom:1px solid var(--border);text-align:left}.admin-table th{background:#111}
.form-panel{max-width:860px;background:var(--panel);border:1px solid var(--border);border-radius:22px;padding:24px}
.login-wrap{min-height:100vh;display:grid;place-items:center;background:radial-gradient(circle at top,#2a0f0f,#0b0b0b 50%)}.login-card{width:min(450px,92%);background:rgba(20,20,20,.95);border:1px solid var(--border);padding:30px;border-radius:24px}
.action-row{display:flex;gap:10px;flex-wrap:wrap}.btn-small{padding:10px 14px;border-radius:12px;font-size:.95rem}.btn-ghost{background:#161616;border:1px solid var(--border);color:#fff}.btn-danger{background:#6b1d1d;color:#fff;border:1px solid #822}
@media (max-width:980px){.hero-content,.grid-2,.contact-grid,.footer-grid,.admin-shell{grid-template-columns:1fr}.services-grid,.videos-grid,.testimonials-grid,.blog-grid,.gallery-grid,.partners-grid,.process-grid,.admin-cards{grid-template-columns:1fr 1fr}.hero-card{max-width:520px}}
@media (max-width:760px){.nav-toggle{display:block}.main-nav{display:none;position:absolute;top:74px;left:4%;right:4%;padding:16px;background:#111;border:1px solid var(--border);border-radius:18px;flex-direction:column;align-items:flex-start}.main-nav.open{display:flex}.services-grid,.videos-grid,.testimonials-grid,.blog-grid,.gallery-grid,.partners-grid,.process-grid,.admin-cards{grid-template-columns:1fr}.hero{min-height:72vh}.hero-content{padding:70px 0}.hero h1{font-size:2.4rem}}


/* Gallery mixed-size handling */
.gallery-grid{
  align-items:start;
}
.gallery-card{
  overflow:hidden;
  position:relative;
  background:var(--panel);
  display:flex;
  flex-direction:column;
}
.gallery-card .gallery-popup-trigger{
  display:block;
  cursor:pointer;
}
.gallery-card img{
  width:100%;
  height:auto !important;
  max-height:none !important;
  object-fit:contain !important;
  background:#0f0f0f;
}
.gallery-card .overlay{
  position:static !important;
  padding:16px 18px;
  background:linear-gradient(180deg, rgba(255,255,255,.02), rgba(0,0,0,.12));
}
.gallery-card .overlay strong{
  display:block;
  margin-bottom:4px;
}

/* Lightbox popup */
.lightbox{
  display:none;
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.92);
  z-index:5000;
  align-items:center;
  justify-content:center;
  padding:24px;
}
.lightbox.open{
  display:flex;
}
.lightbox-inner{
  position:relative;
  max-width:95vw;
  max-height:95vh;
  display:flex;
  align-items:center;
  justify-content:center;
}
.lightbox img{
  max-width:95vw;
  max-height:90vh;
  width:auto;
  height:auto;
  object-fit:contain;
  border-radius:16px;
  background:#111;
}
.lightbox-close{
  position:absolute;
  top:-14px;
  right:-6px;
  width:42px;
  height:42px;
  border:none;
  border-radius:999px;
  background:var(--red);
  color:#fff;
  font-size:24px;
  cursor:pointer;
  line-height:1;
}
body.lightbox-active{
  overflow:hidden;
}

@media (max-width:760px){
  .gallery-card .overlay{
    padding:14px;
  }
  .lightbox{
    padding:14px;
  }
  .lightbox-close{
    top:-10px;
    right:0;
  }
}


/* Boxed gallery layout */
.gallery-grid{
  display:grid;
  grid-template-columns:repeat(3, minmax(0, 1fr));
  gap:22px;
  align-items:stretch;
}

.gallery-card{
  display:flex;
  flex-direction:column;
  height:100%;
  border-radius:22px;
  overflow:hidden;
  background:var(--panel);
  border:1px solid var(--border);
  box-shadow:0 10px 30px rgba(0,0,0,.18);
}

.gallery-card .gallery-popup-trigger{
  display:flex;
  align-items:center;
  justify-content:center;
  width:100%;
  height:320px;
  padding:14px;
  background:#111;
  overflow:hidden;
}

.gallery-card img{
  width:100%;
  height:100% !important;
  object-fit:contain !important;
  object-position:center;
  max-height:100% !important;
  background:#111;
}

.gallery-card .overlay{
  min-height:88px;
  display:flex;
  flex-direction:column;
  justify-content:center;
  padding:16px 18px !important;
  background:linear-gradient(180deg, rgba(255,255,255,.02), rgba(0,0,0,.12));
}

.gallery-card .overlay strong{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.gallery-card .overlay .muted{
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}

@media (max-width:980px){
  .gallery-grid{
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }
}

@media (max-width:760px){
  .gallery-grid{
    grid-template-columns:1fr;
  }
  .gallery-card .gallery-popup-trigger{
    height:280px;
  }
}


/* ===== MASONRY STYLE (ALL IMAGES IN ONE FLOW) ===== */
.gallery-grid{
  column-count:3;
  column-gap:16px;
}

.gallery-card{
  break-inside: avoid;
  margin-bottom:16px;
  border-radius:16px;
  overflow:hidden;
  background:#111;
}

.gallery-card .gallery-popup-trigger{
  display:block;
}

.gallery-card img{
  width:100%;
  height:auto !important;
  object-fit:cover;
}

.gallery-card .overlay{
  display:none; /* clean look */
}

/* responsive */
@media (max-width:980px){
  .gallery-grid{
    column-count:2;
  }
}

@media (max-width:600px){
  .gallery-grid{
    column-count:1;
  }
}


/* ===== CLEAN AUTO-ADJUST GALLERY ===== */
.gallery-grid{
  display:grid !important;
  grid-template-columns:repeat(3,minmax(0,1fr)) !important;
  gap:18px !important;
  column-count:unset !important;
  align-items:start !important;
}

.gallery-card{
  break-inside:auto !important;
  margin-bottom:0 !important;
  background:transparent !important;
  border:none !important;
  box-shadow:none !important;
  border-radius:18px !important;
  overflow:hidden !important;
}

.gallery-card .gallery-popup-trigger{
  display:block !important;
  background:#111 !important;
  border-radius:18px !important;
  overflow:hidden !important;
}

.gallery-card img{
  display:block !important;
  width:100% !important;
  height:auto !important;
  max-height:none !important;
  object-fit:contain !important;
  object-position:center !important;
  background:#111 !important;
  border-radius:18px !important;
  transition:transform .28s ease, opacity .28s ease;
}

.gallery-card:hover img{
  transform:scale(1.02);
}

.gallery-card .overlay{
  display:none !important;
}

@media (max-width: 980px){
  .gallery-grid{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }
}

@media (max-width: 640px){
  .gallery-grid{
    grid-template-columns:1fr !important;
  }
}


/* ===== FINAL CLEAN PINTEREST GALLERY ===== */
/* No crop, no borders, no boxes, natural image ratios */
.gallery-grid{
  display:block !important;
  column-count:3 !important;
  column-gap:18px !important;
  grid-template-columns:none !important;
  gap:0 !important;
  align-items:initial !important;
}

.gallery-card{
  display:block !important;
  break-inside:avoid !important;
  -webkit-column-break-inside:avoid !important;
  page-break-inside:avoid !important;
  margin:0 0 18px 0 !important;
  padding:0 !important;
  background:transparent !important;
  border:none !important;
  box-shadow:none !important;
  border-radius:0 !important;
  overflow:visible !important;
}

.gallery-card .gallery-popup-trigger{
  display:block !important;
  margin:0 !important;
  padding:0 !important;
  background:transparent !important;
  border:none !important;
  border-radius:0 !important;
  overflow:visible !important;
  line-height:0 !important;
}

.gallery-card img{
  display:block !important;
  width:100% !important;
  height:auto !important;
  max-width:100% !important;
  max-height:none !important;
  object-fit:unset !important;
  object-position:center !important;
  background:transparent !important;
  border:none !important;
  border-radius:0 !important;
  box-shadow:none !important;
  margin:0 !important;
  padding:0 !important;
  transition:transform .22s ease !important;
}

.gallery-card:hover img{
  transform:scale(1.012) !important;
}

.gallery-card .overlay{
  display:none !important;
}

@media (max-width: 980px){
  .gallery-grid{
    column-count:2 !important;
    column-gap:14px !important;
  }
  .gallery-card{
    margin-bottom:14px !important;
  }
}

@media (max-width: 640px){
  .gallery-grid{
    column-count:1 !important;
    column-gap:0 !important;
  }
  .gallery-card{
    margin-bottom:12px !important;
  }
}


/* ===== JUSTIFIED GALLERY ===== */
.gallery-grid{
  display:flex !important;
  flex-direction:column !important;
  gap:14px !important;
  column-count:unset !important;
}

.gallery-row{
  display:flex;
  gap:14px;
  width:100%;
}

.gallery-card{
  display:block !important;
  flex:0 0 auto;
  margin:0 !important;
  padding:0 !important;
  background:transparent !important;
  border:none !important;
  box-shadow:none !important;
  border-radius:0 !important;
  overflow:visible !important;
}

.gallery-card .gallery-popup-trigger{
  display:block !important;
  line-height:0 !important;
  background:transparent !important;
}

.gallery-card img{
  display:block !important;
  width:auto !important;
  height:260px !important;
  max-width:none !important;
  max-height:none !important;
  object-fit:contain !important;
  background:transparent !important;
  border:none !important;
  border-radius:0 !important;
  box-shadow:none !important;
  transition:transform .2s ease !important;
}

.gallery-card:hover img{
  transform:scale(1.01) !important;
}

.gallery-card .overlay{
  display:none !important;
}

@media (max-width: 980px){
  .gallery-row{ gap:10px; }
  .gallery-grid{ gap:10px !important; }
  .gallery-card img{ height:200px !important; }
}
@media (max-width: 640px){
  .gallery-row{
    display:block;
  }
  .gallery-grid{ gap:10px !important; }
  .gallery-card{
    margin-bottom:10px !important;
  }
  .gallery-card img{
    width:100% !important;
    height:auto !important;
  }
}

.story-image,.cta-banner-image{
  width:100%;
  display:block;
  border-radius:20px;
  margin-bottom:18px;
}
.cta-visual-block img{
  min-height:220px;
  object-fit:cover;
}
/* =====================================================
   FINAL RESPONSIVE GALLERY
===================================================== */
/* =========================
   PINTEREST GALLERY
========================= */

.pinterest-gallery{
    column-count: 4;
    column-gap: 18px;
}

.gallery-item{
    position: relative;
    display: block;
    margin-bottom: 18px;
    overflow: hidden;
    border-radius: 18px;
    break-inside: avoid;
    cursor: pointer;
}

.gallery-item img{
    width: 100%;
    display: block;
    border-radius: 18px;
    transition: transform .5s ease;
}

.gallery-item:hover img{
    transform: scale(1.05);
}

.gallery-overlay{
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(0,0,0,.75),
        rgba(0,0,0,.1)
    );
    display: flex;
    align-items: flex-end;
    padding: 20px;
    opacity: 0;
    transition: .4s ease;
}

.gallery-item:hover .gallery-overlay{
    opacity: 1;
}

.gallery-overlay span{
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: .5px;
}

/* =========================
   RESPONSIVE
========================= */

@media(max-width:1200px){

    .pinterest-gallery{
        column-count: 3;
    }

}

@media(max-width:768px){

    .pinterest-gallery{
        column-count: 2;
        column-gap: 12px;
    }

    .gallery-item{
        margin-bottom: 12px;
    }

}

@media(max-width:520px){

    .pinterest-gallery{
        column-count: 1;
    }

}

/* =========================
   HERO BANNER 
========================= */

.hims_hero{
    position: relative;
    min-height: 100vh;
    padding: 120px 0;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;

    display: flex;
    align-items: center;
}

/* Dark overlay */

.hims_hero::before{
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.45);
}

.hims_hero-content{
    position: relative;
    z-index: 2;

    width: 100%;
    max-width: 1400px;
    margin: auto;

    display: grid;
    grid-template-columns: 1.2fr .8fr;
    gap: 60px;
    align-items: center;

    padding: 0 40px;
}

/* Hero Text */

.hims_hero h1{
    font-size: 72px;
    line-height: 1.1;
    margin-bottom: 24px;
}

.hims_hero p{
    font-size: 18px;
    line-height: 1.8;
    max-width: 650px;
}

/* Right Card */

.hims_hero-card{
    backdrop-filter: blur(14px);
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 24px;
    padding: 35px;
}

/* =========================
   RESPONSIVE
========================= */

@media(max-width:1100px){

    .hims_hero-content{
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hims_hero p{
        margin: auto;
    }

    .hims_hero-card{
        max-width: 650px;
        margin: auto;
    }

}

@media(max-width:768px){

    .hims_hero{
        min-height: auto;
        padding: 100px 0 80px;
    }

    .hims_hero-content{
        padding: 0 20px;
    }

    .hims_hero h1{
        font-size: 42px;
    }

    .hims_hero p{
        font-size: 16px;
    }

}

@media(max-width:520px){

    .hims_hero h1{
        font-size: 34px;
        line-height: 1.2;
    }

    .hims_hero-card{
        padding: 24px;
    }

}

/* =========================
   HIMS PROFESSIONAL HEADER
========================= */

.hims_header{
    background: #0b0b0b;
    padding: 14px 0;
    position: sticky;
    top: 0;
    z-index: 999;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.hims_nav-wrap{
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* BRAND */
.hims_brand{
    display: flex;
    align-items: center;
    text-decoration: none;
}

.hims_brand-logo{
    height: 55px;
    width: auto;
    object-fit: contain;
    transition: 0.3s ease;
}

.hims_brand-logo:hover{
    transform: scale(1.05);
}

/* NAV */
.hims_main-nav a{
    color: #fff;
    margin-left: 18px;
    text-decoration: none;
    font-size: 15px;
    transition: 0.3s;
}

.hims_main-nav a:hover,
.hims_main-nav a.active{
    color: #b11f1f;
}

/* ADMIN */
.hims_nav-admin{
    padding: 6px 12px;
    border: 1px solid #b11f1f;
    border-radius: 6px;
}

/* TOGGLE */
.hims_nav-toggle{
    display: none;
    font-size: 22px;
    color: #fff;
    background: none;
    border: none;
}

/* RESPONSIVE */
@media(max-width:768px){

    .hims_brand-logo{
        height: 42px;
    }

    .hims_main-nav{
        display: none;
    }

    .hims_nav-toggle{
        display: block;
    }

}