.name-tool{max-width:1000px;margin-inline:auto}.color-form{display:flex;align-items:end;justify-content:center;gap:12px;flex-wrap:wrap}.color-field{display:grid;gap:2px}.color-field label{font-weight:600}.color-field input[type=text]{height:42px;width:230px;max-width:100%;padding:8px 12px;border:1px solid #b8cbd7;border-radius:8px;background:#fff;font:18px/1.5 Consolas,monospace;text-align:left}.color-field input[aria-invalid=true]{border-color:#b42318}.color-field input[type=color]{width:42px;height:42px;padding:0;border:1px solid #b8cbd7;border-radius:8px;background:#fff;cursor:pointer}.color-form .page-button{height:42px;padding-block:0}.hex-note{text-align:center;font-size:12px;color:#666;margin-top:12px}.color-error{color:#a51d16;text-align:center;min-height:2em;margin:12px 0}.color-samples{display:flex;flex-wrap:wrap;justify-content:center;gap:8px;margin:16px 0}.color-samples button{display:flex;align-items:center;gap:8px;border:1px solid #dfe8ee;border-radius:24px;background:white;padding:6px 12px;font:13px/1.8 Arial,sans-serif;color:#353535}.sample-dot{width:16px;height:16px;border:1px solid #0002;border-radius:50%}.color-result[hidden],.manual-copy[hidden]{display:none}.match-summary{text-align:center;margin:24px 0}.match-summary h3{font:600 28px/1.5 Arial,sans-serif;overflow-wrap:anywhere;margin:8px 0}.match-type{color:#07568f;font-weight:600}.match-summary p{margin-bottom:6px}.comparison{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}.color-card{background:#fff;border:1px solid #dfe8ee;border-radius:12px;overflow:hidden;min-width:0}.color-card h3{padding:16px 18px;margin:0;font-size:15px}.color-swatch{height:140px;border-block:1px solid #0001}.color-card-body{padding:16px 18px}.color-card code{display:block;font:16px/1.8 Consolas,monospace;overflow-wrap:anywhere}.color-card .text-actions{margin-top:12px}.name-copy{margin-top:10px}.match-note{margin:12px auto 20px auto;max-width:760px;text-align:center;color:#555}.alternatives-title{text-align:center;font-size:15px;margin-top:26px}.alternatives{display:flex;flex-wrap:wrap;gap:12px;justify-content:center;list-style:none;padding:0;margin:12px 0}.alternatives li{display:flex;align-items:center;gap:8px;padding:8px 8px 8px 14px;background:#fff;border:1px solid #dfe8ee;border-radius:40px;font:13px/1.7 Arial,sans-serif}.alternative-swatch{flex:none;width:26px;height:26px;border-radius:100%;border:1px solid #0002}.name-tool .tool-status{text-align:center}.manual-copy{text-align:center}.manual-copy input{display:block;margin:8px auto;padding:10px;max-width:100%;font:16px Arial,sans-serif}.name-guide{max-width:860px;margin-inline:auto}.name-guide h2,.name-faq h2{text-align:center}.name-guide a{overflow-wrap:anywhere}.name-guide li{margin-bottom:8px}.name-faq .faq-list{max-width:860px}.name-tool bdi,.name-tool code{font-family:Arial,sans-serif}.name-guide .source-note{font-size:12px;color:#666;margin-top:24px}
@media(max-width:575px){.comparison{grid-template-columns:1fr}.color-swatch{height:125px}.color-form{align-items:end}.color-field:first-child{flex:1;min-width:0}.color-field input[type=text]{width:100%}.color-form .page-button{width:100%}.match-summary h3{font-size:24px}}

.color-field input[type=color]{border-radius:8px;overflow:hidden}.color-field input[type=color]::-webkit-color-swatch-wrapper{padding:0}.color-field input[type=color]::-webkit-color-swatch{border:0;border-radius:7px}.color-field input[type=color]::-moz-color-swatch{border:0;border-radius:7px}


/* Shared reading width for the introduction and naming guide. */
.tool-hero .section-heading > p{max-width:1100px;margin-inline:auto}
body .tool-wrap.name-guide{max-width:1100px}

.color-result{background:var(--soft);padding:64px 32px;border-radius:14px}.color-result .match-summary{margin-top:0}.color-result .alternatives{margin-bottom:0}
@media(width < 767px){.color-result{padding:54px 16px}}

/* Extend the result background across the page without widening its content. */
.color-result{position:relative;isolation:isolate;border-radius:0;background:transparent}
.color-result::before{content:"";position:absolute;inset:0;left:50%;right:auto;width:100vw;transform:translateX(-50%);background:var(--soft);z-index:-1;pointer-events:none}
body:has(.color-result){overflow-x:clip}

/* The result ends the hero; the following guide supplies its own top padding. */
.main > .tool-hero{padding-bottom:0}
.name-tool #copy-status:empty{min-height:0;height:0;margin:0}

.color-card-body{display:flex;align-items:center;justify-content:space-between;gap:12px;direction:ltr;overflow-x:auto}.color-card-body code{display:inline-block;margin:0;white-space:nowrap;flex:0 0 auto}

#match-note{font-size:12px}

.color-samples button{font-family:IRANYekanXFaNum,Tahoma,sans-serif}

.color-palettes{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:24px}.color-palettes[hidden],#palettes-empty[hidden]{display:none}.palette-card{min-width:0;border:1px solid #dfe8ee;border-radius:12px;padding:20px;background:#fff}.palette-card h3{font-size:16px;margin:0 0 8px}.palette-card p{font-size:13px;color:#666;margin:0 0 16px}.palette-swatches{display:flex;list-style:none;padding:0;margin:0;gap:10px;direction:ltr}.palette-swatches li{flex:1;min-width:0;padding:0;text-align:center}.palette-swatch{display:block;height:70px;border:1px solid #0001;border-radius:14px}.palette-swatches code{display:block;margin-top:8px;font:12px/1.5 Arial,sans-serif;white-space:nowrap}@media(max-width:767px){.color-palettes{grid-template-columns:1fr}.palette-card{padding:16px}.palette-swatches{gap:6px}.palette-swatches code{font-size:11px}}

.palette-swatch.palette-swatch-selected{outline:none;border:1px solid #0b66a9;box-sizing:border-box;box-shadow:inset 0 0 0 2px #fff}
.name-guide>p{text-align:justify; text-align-last: center;}

/* Halve the shared gap between the palette and naming guide sections. */
.main>.color-palettes-section{padding-block-end:32px}
.main>.color-palettes-section+.name-guide-section{padding-top:32px}
@media(width < 767px){.main>.color-palettes-section{padding-block-end:27px}.main>.color-palettes-section+.name-guide-section{padding-top:27px}}
