/* Arshism 1.1.4 — production fixes for paired hero, responsive cards,
   naturally sized images and an independent consultation form. */

/* Hero: copy on the right, artwork on the left, and actions immediately under copy. */
.home-hero{
  display:grid;
  grid-template-columns:minmax(0,1.05fr) minmax(0,1.15fr);
  grid-template-areas:"copy art" "actions art";
  grid-template-rows:auto auto;
  align-content:center;
  align-items:center;
  column-gap:20px;
  row-gap:0;
}
.home-hero>.hero-copy{grid-area:copy;align-self:end;min-width:0}
.home-hero>.hero-art{grid-area:art;align-self:center;min-width:0}
.home-hero>.hero-action-row{grid-area:actions;align-self:start;display:flex;flex-wrap:wrap;gap:12px;margin:16px 0 0;min-width:0}
.home-hero>.hero-action-row>.button{min-width:0;width:auto}
.hero-art .hero-picture{display:block;width:100%;height:auto}
.hero-art .hero-picture--night{display:none}
.hero-art .hero-picture img{display:block;width:100%;height:auto;object-fit:contain;max-height:none}
.hero-art .hero-picture--day img{mix-blend-mode:multiply}
html[data-theme="dark"] .hero-art .hero-picture--day{display:none}
html[data-theme="dark"] .hero-art .hero-picture--night{display:block}
html[data-theme="dark"] .hero-art .hero-picture--night img,
html[data-theme="dark"] .home-hero .hero-art>img{mix-blend-mode:normal!important;filter:none!important}
html[data-theme="dark"] .home-hero .hero-art{background:transparent;border:0;box-shadow:none}

/* Avoid fixed height/letterbox bars on cover images in articles and samples. */
body.arshism-pearl .article-card .article-art,
body.arshism-pearl .featured-article-list .article-card .article-art{
  min-height:0!important;max-height:none!important;height:auto!important;
  padding:0!important;background:transparent!important;align-self:start;overflow:hidden;
}
body.arshism-pearl .article-card .article-art picture,
body.arshism-pearl .article-card .article-art img,
body.arshism-pearl .featured-article-list .article-card .article-art img{
  display:block;width:100%!important;height:auto!important;max-height:none!important;
  min-height:0!important;object-fit:contain!important;aspect-ratio:auto!important;
}
body.arshism-pearl .article-cover img,
body.arshism-pearl .project-full img,
body.arshism-pearl .showcase-example-image img,
body.arshism-pearl .legacy-gallery-card img{
  width:100%;height:auto!important;object-fit:contain!important;aspect-ratio:auto!important;
}

/* Contact page: remove the heavy panel behind the "از ایده‌تان بگویید" intro
   in night mode so it matches the day layout. */
.arshism-contact-page .page-intro,
html[data-theme="dark"] .arshism-contact-page .page-intro{
  background:transparent!important;border:0!important;border-radius:0!important;
  box-shadow:none!important;padding:0!important;
}
.arshism-contact-page .page-illustration,
html[data-theme="dark"] .arshism-contact-page .page-illustration{
  background:transparent!important;border:0!important;box-shadow:none!important;
}
.arshism-contact-page .contact-grid{align-items:start}
.arshism-inquiry-page-panel{padding:24px 28px}
.arshism-inquiry-page-panel>h2{font-size:25px;margin:0 0 6px}
.arshism-inquiry-page-panel>p{color:var(--muted);font-size:14px;margin:0 0 20px}

/* New, independent inquiry form — all required fields visible in popup and page. */
.arshism-consult-dialog{max-width:min(610px,calc(100vw - 28px));width:610px;max-height:min(88dvh,780px);overflow-y:auto;padding:30px 32px}
.arshism-consult-dialog>h2{font-size:28px;margin:0 0 6px}
.arshism-consult-dialog>p:not(.eyebrow){font-size:14px;color:var(--muted);margin:0 0 19px}
.arshism-inquiry-form{min-width:0}
.arshism-inquiry-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:15px}
.arshism-inquiry-field{display:flex;flex-direction:column;gap:6px;min-width:0}
.arshism-inquiry-field label{font-size:14px;font-weight:750;color:var(--text)}
.arshism-inquiry-field label span{color:#e2594f}
.arshism-inquiry-span{grid-column:1/-1}
.arshism-inquiry-field input,.arshism-inquiry-field textarea,.arshism-inquiry-field select{
  display:block;width:100%;min-width:0;min-height:48px;padding:10px 13px;
  background:#fff;border:1px solid #d5deef;border-radius:12px;color:#18233b;
  font-family:inherit;font-size:15px;line-height:1.75;outline-offset:3px;
}
.arshism-inquiry-field textarea{resize:vertical;min-height:100px}
.arshism-inquiry-field input:focus,.arshism-inquiry-field textarea:focus,.arshism-inquiry-field select:focus{border-color:var(--primary);box-shadow:0 0 0 3px #3166ff22;outline:none}
.arshism-inquiry-field input::placeholder,.arshism-inquiry-field textarea::placeholder{color:#8592aa}
.arshism-inquiry-submit{width:100%;margin-top:15px;display:flex;gap:10px;justify-content:center}
.arshism-inquiry-privacy{margin:8px 0 0;color:var(--muted);font-size:12px;line-height:1.8;text-align:center}
.arshism-inquiry-feedback{padding:10px 13px;border-radius:11px;font-size:14px;line-height:1.8;margin:12px 0 2px}
.arshism-inquiry-feedback.is-success{background:#e8f9f2;border:1px solid #b3e8cb;color:#075d3e}
.arshism-inquiry-feedback.is-error{background:#fff0ef;border:1px solid #f4c0bf;color:#8b2121}
.arshism-honeypot{position:absolute!important;left:-10000px!important;width:1px!important;height:1px!important;opacity:0!important;overflow:hidden!important}
html[data-theme="dark"] .arshism-inquiry-field input,
html[data-theme="dark"] .arshism-inquiry-field textarea,
html[data-theme="dark"] .arshism-inquiry-field select{
 background:#101f3a;border-color:#304665;color:#f1f5ff;
}
html[data-theme="dark"] .arshism-inquiry-field label{color:#ebf3ff}
html[data-theme="dark"] .arshism-inquiry-field input::placeholder,
html[data-theme="dark"] .arshism-inquiry-field textarea::placeholder{color:#8aa0be}
html[data-theme="dark"] .arshism-inquiry-feedback.is-success{background:#0e332f;border-color:#1d6e5d;color:#b1f5dd}
html[data-theme="dark"] .arshism-inquiry-feedback.is-error{background:#3e1a26;border-color:#7c2d46;color:#ffd9df}

/* On tablets, preserve the two-column top composition and three feature cards. */
@media (max-width:980px){
 .home-hero{grid-template-columns:minmax(0,1.13fr) minmax(0,.87fr);min-height:0;gap:12px 15px;padding:25px 0 16px;grid-template-areas:"copy art" "actions actions"}
 .home-hero>.hero-copy{align-self:center}
 .home-hero>.hero-art{width:100%;max-width:none;margin:0;animation:none}
 .home-hero>.hero-action-row{margin:0;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}
 .home-hero>.hero-action-row>.button{width:100%;font-size:14px;min-height:46px;padding:9px 10px}
 .home-hero h1{font-size:clamp(23px,3.8vw,40px);line-height:1.48;padding-bottom:10px;margin-bottom:10px}
 .home-hero .eyebrow{font-size:clamp(11px,1.8vw,14px);margin-bottom:9px}
 .home-hero .hero-description{font-size:clamp(12px,1.55vw,16px);line-height:1.75;margin:10px 0 0}
 .feature-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
 .feature-grid .feature-card{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;min-width:0;min-height:150px;padding:15px 9px;gap:5px}
 .feature-grid .feature-illustration{width:58px;height:60px;flex-shrink:0}
 .feature-grid .feature-illustration .pearl-illustration,.feature-grid .feature-illustration img{width:100%;height:100%;object-fit:contain}
 .feature-grid .feature-card h2{font-size:clamp(13px,1.75vw,18px);line-height:1.45;margin:0 0 4px}
 .feature-grid .feature-card p{font-size:clamp(10px,1.3vw,13px);line-height:1.55}
}
@media (max-width:620px){
 .home-hero{grid-template-columns:minmax(0,1.09fr) minmax(0,.91fr);column-gap:5px;row-gap:14px;padding-block:21px 14px}
 .home-hero .hero-copy{min-width:0}
 .home-hero h1{font-size:clamp(20px,5.6vw,27px);line-height:1.5;margin:0 0 9px;padding-bottom:8px;letter-spacing:0}
 .home-hero h1::after{width:32px;height:3px}
 .home-hero .eyebrow{font-size:10px;margin:0 0 8px;gap:6px}
 .home-hero .eyebrow::before{width:12px;height:2px}
 .home-hero .hero-description{font-size:11.5px;line-height:1.7;margin-top:8px}
 .home-hero>.hero-action-row{gap:9px}
 .home-hero>.hero-action-row>.button{font-size:12.5px;padding:9px 6px;min-height:44px;border-radius:11px;white-space:normal}
 .feature-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}
 .feature-grid .feature-card{min-height:129px;padding:10px 5px;border-radius:14px;gap:3px}
 .feature-grid .feature-illustration{width:47px;height:47px}
 .feature-grid .feature-card h2{font-size:clamp(11px,3vw,14px);line-height:1.4}
 .feature-grid .feature-card p{font-size:10px;line-height:1.5}
 .showcase-category-grid,
 .showcase-category-grid.showcase-category-grid--home,
 .showcase-category-grid.showcase-category-grid--directory{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
 .showcase-category-grid .showcase-category-card{display:flex;flex-direction:column;justify-content:flex-start;align-items:center;min-width:0;min-height:178px;padding:10px 8px;border-radius:15px;gap:5px;text-align:center}
 .showcase-category-grid .showcase-category-art{flex:0 0 auto;width:70px;height:68px;max-width:70px;min-width:0;border-radius:12px}
 .showcase-category-grid .showcase-category-art .pearl-illustration{padding:3px}
 .showcase-category-grid .showcase-category-art .pearl-illustration img{width:100%;height:100%!important;max-height:62px}
 .showcase-category-grid .showcase-category-copy{align-items:center;flex:0 1 auto;padding:0;gap:1px}
 .showcase-category-grid .showcase-category-kicker{display:none}
 .showcase-category-grid .showcase-category-title{font-size:15px;line-height:1.4}
 .showcase-category-grid .showcase-category-description{font-size:10px;line-height:1.55;max-width:none;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
 .showcase-category-grid .showcase-category-action{font-size:10.5px;margin:2px 0 0;gap:3px}
 .showcase-category-grid .showcase-category-action span{font-size:14px}
 .arshism-contact-page .contact-grid{grid-template-columns:1fr}
 .arshism-inquiry-page-panel{padding:20px 16px}
 .arshism-consult-dialog{max-height:calc(100dvh - 24px);width:calc(100vw - 20px);padding:24px 18px}
 .arshism-consult-dialog>h2{font-size:23px}
 .arshism-inquiry-fields{gap:11px}
 .arshism-inquiry-field label{font-size:12.5px}
 .arshism-inquiry-field input,.arshism-inquiry-field textarea,.arshism-inquiry-field select{font-size:14px;padding:9px 10px;min-height:44px}
 .arshism-inquiry-submit{font-size:14px}
 .mobile-cta{padding:9px 0 calc(9px + var(--safe-bottom))}
 .mobile-cta .button{min-height:46px;font-size:14px}
}
@media (max-width:355px){
 .home-hero h1{font-size:19px}
 .home-hero .hero-description{font-size:10.5px}
 .feature-grid .feature-card{min-height:138px}
 .feature-grid .feature-card h2{font-size:11px}
 .feature-grid .feature-card p{font-size:9.5px}
 .showcase-category-grid .showcase-category-title{font-size:13px}
 .showcase-category-grid .showcase-category-card{min-height:166px}
 .showcase-category-grid .showcase-category-art{width:59px;height:57px;max-width:59px}
}
@media(prefers-reduced-motion:reduce){.home-hero .hero-art{animation:none}}
/* Override the legacy mix-blend on BOTH picture and img (mobile Safari included). */
html[data-theme="dark"] .home-hero .hero-art .hero-picture--night,
html[data-theme="dark"] .home-hero .hero-art .hero-picture--night img{mix-blend-mode:normal!important}
