/* Conservative responsive retrofit for the legacy public site. */
html { box-sizing: border-box; overflow-x: hidden; }
*, *:before, *:after { box-sizing: inherit; }
body { overflow-x: hidden; }
body { line-height: 1.55; }
img, video, canvas, svg, iframe { max-width: 100%; height: auto; }
input, select, textarea, button { max-width: 100%; }
table { max-width: 100%; }
.cart-item { width: 75%; }
.cart-checkout-action { float: right; margin: 10px 0; }
#mobile-menu-toggle, .submenu-toggle { display: none; }
a:focus, button:focus, input:focus, select:focus, textarea:focus {
    outline: 3px solid #f58220;
    outline-offset: 2px;
}

/* Shared visual finish. These rules deliberately retain the original palette. */
div.entry, div.widget, div#services {
    border-color: #d8d8d8;
    box-shadow: 0 2px 8px rgba(0,0,0,.06);
}
div.entry-content p, div.widget-content p, div.col-content p { line-height: 1.58; }
div.entry-content h1, div.entry-content h2, div.entry-content h3 { line-height: 1.25; }
.buttonize, .cta-button, input[type="submit"], button {
    border-radius: 3px;
    transition: background-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.buttonize:hover, .cta-button:hover, input[type="submit"]:hover { box-shadow: 0 2px 6px rgba(0,0,0,.18); }
input[type="text"], input[type="email"], input[type="password"], select, textarea {
    border-radius: 2px;
}

/* Legacy desktop cards use declared content widths plus horizontal padding. */
@media screen and (min-width: 1001px) {
    div.entry-content, div.comment-content { box-sizing: content-box; }
}

@media screen and (max-width: 1000px) {
    div.wrapper, div.footer-content, div#services, div#services-content,
    div#services-bottom, div#bottom-container {
        width: auto;
        max-width: 960px;
        margin-left: 20px;
        margin-right: 20px;
    }
    div#content { width: calc(100% - 330px); }
    div.entry-content, div.comment-content { width: auto; background-color: #fff; }
    div.post-meta-data p, p.submit-container, div.wp-pagenavi { width: auto; }
    div#feature-projects-container, div#feature-projects-content { width: 100%; }
    div#feature-projects-container { left: 0; margin-left: 0; }
}

@media screen and (max-width: 960px) {
    div.wrapper, div.footer-content, div#services, div#services-content,
    div#services-bottom, div#bottom-container {
        max-width: none;
        margin-left: 16px;
        margin-right: 16px;
    }
    div#header { height: auto; min-height: 222px; padding-top: 54px; }
    h1#logo a { top: 54px; max-width: calc(100% - 220px); background-size: contain; }
    div#header-pnone { top: 174px; width: auto; max-width: calc(100% - 220px); }
    div#header-box { top: 84px; right: 0; }
    div#nav-content { left: 0; right: 0; top: 0; bottom: auto; height: auto; padding: 0; background: none; z-index: 30; }
    #mobile-menu-toggle {
        display: block; width: 100%; min-height: 44px; padding: 10px 14px;
        border: 1px solid #555; border-radius: 3px; background: #333; color: #fff;
        font: bold 14px Arial, sans-serif; text-align: left; cursor: pointer;
    }
    #mobile-menu-toggle span { float: right; font-size: 20px; line-height: 14px; }
    ul#nav { display: none; float: none; position: absolute; top: 44px; left: 0; right: 0; background: #333; z-index: 1000; }
    ul#nav.is-open { display: block; }
    ul#nav > li, ul#nav li li { float: none; width: 100%; height: auto; min-height: 44px; background: none; border-top: 1px solid #4d4d4d; }
    ul#nav li span { display: none !important; }
    ul#nav li a { position: relative; display: block; width: auto; min-height: 44px; padding: 13px 52px 11px 15px; line-height: 20px; text-align: left; }
    ul#nav li ul, ul#nav li ul li ul { display: none !important; position: static; width: 100%; visibility: visible !important; background: #242424; }
    ul#nav li.submenu-open > ul { display: block !important; }
    ul#nav li li a { padding-left: 30px; }
    .submenu-toggle {
        display: block; position: absolute; z-index: 2; right: 2px; top: 2px;
        width: 44px; height: 40px; border: 0; border-left: 1px solid #555;
        background: transparent; color: #fff; font-size: 24px; cursor: pointer;
    }
    div#feature-projects { height: auto; min-height: 340px; background-position: center top; }
    div#feature-projects-bg { display: none; }
    div#featured-projects-text { left: 20px; max-width: 38%; }
    div#JSlides { right: 20px; width: 55%; }
    div#services, div#services-content, div#services-bottom { background-image: none; }
    div#services { border: 1px solid #ddd; background: #fff; }
    div.services-col1, div.services-col2, div.services-col3 { width: 33.333%; margin-left: 0; }
    div#content, div#sidebar { float: none; width: 100%; margin-top: 24px; }
    div#sidebar { display: flex; flex-wrap: wrap; gap: 20px; }
    div#sidebar > .widget { flex: 1 1 280px; min-width: 0; }
    div.widget-content, div.widget_categories, div.widget-top, div.widget-bottom { background-image: none; background-color: #fff; }
    div.widget { border: 1px solid #ddd; }
    div.widget-content p { width: auto; }
    div.entry-top, div.entry-bottom, div.comment-top, div.comment-bottom { background-image: none; background-color: #fff; }
    div.entry { border: 1px solid #ddd; background: #fff; }
    div.entry-content { padding: 22px 24px; background-image: none; }
    div#content-wide { margin-top: 28px; }
    div#bottom-left, div#bottom-right, div#bottom-left-content, div#bottom-right-content { width: 100%; float: none; margin-left: 0; background-image: none; }
    .db-block[style] { width: 100% !important; }
    .cart-item { width: 100%; }
    .ui-dialog { max-width: calc(100vw - 32px) !important; }
}

@media screen and (max-width: 768px) {
    body { font-size: 14px; line-height: 1.55; }
    h1#logo { margin: 0; }
    h1#logo a {
        top: 54px; left: 50%; transform: translateX(-50%);
        width: 340px; height: 108px; max-width: calc(100% - 24px);
        background-position: center center; background-size: contain;
    }
    div#header { min-height: 286px; padding-top: 158px; }
    div#header-pnone { top: 157px; left: 0; width: 100%; max-width: 100%; text-align: center; }
    div#header-pnone span { font-size: 12px; letter-spacing: 2px; }
    div#header-box {
        top: 182px; left: 0; right: auto; width: 100%; min-height: 96px;
        display: block; border-top: 1px solid rgba(255,255,255,.08); padding-top: 7px;
    }
    div#header-box > p { margin: 0 0 4px; color: #fff; text-align: center; white-space: nowrap; }
    div#cart_widget { width: 100%; min-height: 66px; }
    div#cart_widget_inner { display: flex; align-items: center; justify-content: space-between; width: 100%; }
    div#cart_items, div#cart_widget_inner > div { float: none !important; }
    div#cart_items p { margin: 0; line-height: 1.25; }
    div#cart_items p br + br { display: none; }
    div#feature-projects {
        min-height: 0; height: auto; padding: 0 0 18px;
        background: linear-gradient(135deg,#b96717 0%,#f3a528 100%);
    }
    div#feature-projects-container, div#feature-projects-content {
        min-height: 0; height: auto; position: relative; width: auto;
    }
    div#feature-projects-container { margin: 0 16px; left: auto; background: none; }
    div#feature-projects-content { display: flex; flex-direction: column; }
    div#featured-projects-text {
        order: 1; position: relative; left: auto; top: auto; width: auto; max-width: none; height: auto;
        padding: 24px 20px 18px;
    }
    div#featured-projects-text h1 { margin: 0; padding: 0 0 8px; font-size: 19px; line-height: 1.22; }
    div#featured-projects-text p { margin: 0; padding: 0; font-size: 14px; line-height: 1.5; }
    div#JSlides {
        order: 2; display: block !important; position: relative !important; right: auto !important; top: auto !important;
        width: 100% !important; height: auto !important; margin: 0; padding: 0;
        overflow: hidden; border-radius: 3px; box-shadow: 0 5px 18px rgba(0,0,0,.25);
    }
    div#JSlides #mySlides { display: block !important; position: static !important; width: 100% !important; height: auto !important; margin: 0 !important; }
    div#JSlides #mySlides > div { display: none !important; position: static !important; float: none !important; width: 100% !important; height: auto !important; }
    div#JSlides #mySlides > div:first-child { display: block !important; }
    div#JSlides a, div#JSlides img { display: block; width: 100%; height: auto; margin: 0; }
    div#myController { display: none; }
    div.services-col1, div.services-col2, div.services-col3 { float: none; width: 100%; border-bottom: 1px solid #ddd; }
    div.services-col3 { border-bottom: 0; }
    div.col-content { padding-bottom: 15px; }
    div#sidebar { display: block; margin-top: 20px; }
    div#sidebar > .widget { width: 100%; }
    div#sidebar > .widget + .widget { margin-top: 16px; }
    div.comment-avatar, div.comment-text { float: none; width: 100%; }
    div.post-meta-data, div.database-meta-data, div.database-meta-category { height: auto; min-height: 40px; overflow: auto; }
    div.post-meta-data p { padding-right: 45px; }
    blockquote { margin-left: 0; }
    div.footer-content, div.blog { height: auto; min-height: 210px; padding: 28px 0 70px; overflow: visible; }
    div.footer-nav, div.copyright { position: static; }
    div.footer-nav ul { display: flex; flex-wrap: wrap; gap: 8px 14px; }
    div.footer-nav ul li { float: none; margin: 0; }
    div.footer-nav ul li:nth-child(even) { display: none; }
    div.copyright { margin-top: 25px; }
    div.copyright p { text-align: left; }
    div#rss, div#twitter { display: none; }
    a#top { left: 0; bottom: 25px; }
    form#frm_login label, form#frm_register label, form#frm_forgot label,
    form#frm_confirm label, form#frm_pass label, form#frm_modify label,
    form#frm_contact label, form#commentform label {
        float: none; display: block; width: auto; text-align: left; padding: 0 0 5px;
    }
    div.entry-content input[type="text"], div.entry-content input[type="password"],
    form#frm_contact select, input#author, input#email, input#url, #comment-textarea,
    .iput, div.rascals-form input, div.rascals-form textarea, .txtarea,
    form#frm_quote input[type="text"], form#frm_quote textarea, form#frm_quote select,
    form#frm_sitesale input[type="text"], form#frm_sitesale textarea, form#frm_sitesale select,
    input#db_srch, input#domainToCheck, select#TLD {
        width: 100%; min-height: 44px; float: none;
    }
    textarea, #comment-textarea, div.rascals-form textarea { min-height: 140px; }
    div.rascals-form-submit { width: 100%; }
    input[type="submit"], button, .buttonize, .cta-button { min-height: 44px; }
    input.searchsubmit {
        display: block; float: right; width: 60px; min-height: 0; height: 30px;
        margin: 12px 0 0; padding: 0;
    }
    form#search fieldset:after { content: ""; display: table; clear: both; }
    table { display: block; width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .cart-checkout-action { float: none; text-align: center; }
    .cart-checkout-action a, .cart-checkout-action img { display: inline-block; }
}

@media screen and (max-width: 480px) {
    div.wrapper, div.footer-content, div#services, div#services-content,
    div#services-bottom, div#bottom-container { margin-left: 10px; margin-right: 10px; }
    div.entry-content, div#entry-wide { padding: 18px 16px; }
    div#header { min-height: 286px; }
    div#header-box > p { font-size: 11px; }
    div#header-pnone { top: 154px; }
    div#feature-projects-container { margin-left: 10px; margin-right: 10px; }
    div#featured-projects-text { padding: 20px 10px 15px; }
    div#featured-projects-text h1 { font-size: 17px; }
    div#featured-projects-text p { font-size: 13px; }
    h1 { font-size: 20px; line-height: 1.25; }
    h2 { font-size: 18px; line-height: 1.3; }
    .alignleft, .alignright, img.alignleft, img.alignright { float: none; display: block; margin: 0 auto 15px; }
    div.database-wrapper, div.database-tools, div.database-tools a, div.database-tools .recs { float: none; }
    div.database-tools a { display: inline-block; margin: 4px; }
    .db-block-content { min-width: 0; overflow-wrap: anywhere; }
    .buttonize, .cta-button { display: inline-block; margin: 4px 2px; }
}
