:root {
    --main-color: #8302e8;
}

#tntech-show-tariff-wrap {
    width: 100%;
    max-width: 1600px;
    margin: 20px auto;
    font-family: Arial, sans-serif;
}

.tabs {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

#tariffs-s-r{
    display: flex;
    padding-top: 50px;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}
#address-input-wrap{
    display: inline-block;
    position: relative;
    min-width: 300px;
}

#search-tariff {
    padding-top: 20px;
}

#suggestions {
    position: absolute;
    border: 1px solid #ccc;
    background: white;
    z-index: 1;
    max-height: 200px;
    overflow-y: auto;
    width: 300px;
    display: none;
}
.suggestion-item {
    padding: 8px;
    cursor: pointer;
    border-bottom: 1px solid #cecece;
}
.suggestion-item:hover {
    background-color: #f0f0f0;
}

#loading-tariff{
    position: absolute;
    margin-top: 11px;
    display: inline-block;
    width: auto;
    right: 12px;
    height: auto;
    top: 0px;
}

.loading-container {
    display: none;
    flex-direction: column;
    align-items: center;
    margin-top: 16px;
}

#loading-tariff.hidden{
    display: none;
}

.loading-spinner {
    width: 22px;
    height: 22px;
    border: 2px solid #989898;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.tarif-card .check-availability:hover {
    background-color: #aa68e2;
}



.tabs .tab-button {
    background-color: #f4f4f4;
    color: #333;
    border: 1px solid #ddd;
    padding: 14px 50px;
    font-size: 15px;
    font-weight: bold;
    border-radius: 20px;
    margin-right: 10px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
.tabs .tab-button.active {
    background-color: var(--main-color);
    color: white;
}

.tab-content {
    padding: 20px;
    border-radius: 0 0 5px 5px;
}

.tab-panel {
    display: none;
}

.tab-panel.active {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0px;
}

.tarif-card {
    position: relative;
    background: white;
    padding: 15px;
    border: 1px solid  var(--main-color);
    border-radius: 5px;
    width: 220px;
    text-align: center;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.1);
}

.tarif-card del {
    color: #888;
}

.tarif-card h3 {
    color: #102b82;
    margin: 10px 0px 12px 0px;
    font-size: 21px;
    font-weight: bold;
}

.tarif-text {
    min-height: 290px;
}

.tarif-card .discount {
    color: var(--main-color);
    font-weight: bold;
}

.tarif-price .discount {
    font-size: 28px;
}

.check-availability {
    padding: 10px;
    background: #28a745;
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 5px;
    margin-top: 10px;
}

.check-availability:hover {
    background: #aa68e2;
}

#tariffs-s-r .check-availability {
    font-size: 14px;
    color:#fff;
}
.elementor-element.modal-overlay,
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: flex-start;
    padding-top: 100px;
    z-index:10000;
    overflow-y: auto;
}


.modal-inner {
    background: #ffffff;
    padding: 0px;
    border-radius: 40px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
    width: 750px;
    max-width:90%;
    text-align: center;
}
.close-btn-modal {
    position: absolute;
    top: 10px;
    right: 22px;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    color: #000;
}

.form-row {
    clear: both;
    width: 100%;
    margin-bottom: 15px;
    float: left;
}
.cleaner {
    width: 100%;
    clear: both;
}

.modal-inner input[type="submit"] {
    -webkit-appearance: none;
    box-shadow: none;
    background: #666666;
    color: #ffffff;
    padding: 0 15px;
    height: 50px;
    border-radius: 2px;
    border: 0;
    display: block;
    margin: auto;
}

.form-content-tariff {
    padding: 40px 30px 10px 30px;
}

.form-row .form-column {
    width: 50%;
    float: left;
    padding-left: 0;
    padding-right: 10px;
}

.form-content-tariff  h2 {
    font-size: 26px;
    padding-bottom: 10px;
}

.form-content-tariff label{
    text-align: left;
}

#tariffs-s-r  .tarif-card{
    width: 300px;
}

.tab-panel {
    display: none;
}

#tntech-show-tariff-wrap .tab-panel.active {
    display: flex;
}

.tab-panel .tarif-card {
    background: white;
    padding: 20px 20px;
    border-radius: 28px;
    width: 220px;
    text-align: center;
    border: 1px solid #e9e3f3;
    margin: 10px;
    flex: 1 1 calc(15% - 20px);
    max-width: 240px;
}

.contact-button,
.tarif-card .check-availability {
    background-color: var(--main-color);
    color: white;
    border: none;
    border-radius: 20px;
    padding: 10px 20px;
    cursor: pointer;
    display: inline-block;
    font-size: 14px;
    font-weight: 700;
    transition: background-color 0.3s ease;
}
.tarif-card p,
.tab-panel .tarif-card p{
    font-size: 15px;
    color: #393c3d;
}

.download .speed{
    font-size: 30px;
    font-weight: bold;
    color: var(--main-color);
}

.tarif-search-container {
    margin-top: 40px;
    text-align: center;
}

.tarif-search-container input[type="text"] {
    padding: 10px;
    width: 100%;
    max-width: 300px;
    margin-right: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.tarif-search-container button {
    padding: 10px 20px;
    background-color: var(--main-color);
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.tarif-search-container button:hover {
    background-color: #aa68e2;
}

.tarif-search-container label {
    display: block;
    text-align: center;
    padding-bottom: 8px;
    font-weight: bold;
    max-width: 750px;
    margin: auto;
    font-size: 24px;
}

@media (max-width: 768px) {
    .tarif-search-container label {
        max-width: 90%;
        font-size: 22px;
    }

    .modal-inner {
        max-width: 600px;
        width: 100%;
    }

    .form-row .form-column{
        width: 100%;
        float: none;
    }

    .form-content-tariff input{
        width: 100%;
    }
}

.tarif-search-container span {
    font-size: 22px;
}

#availability-result {
    margin-top: 20px;
    font-size: 16px;
    color: #333;
}
@media (max-width: 1600px) {
    #tntech-show-tariff-wrap {
        max-width: 1000px;
    }
    .tab-panel .tarif-card{
        flex: 1 1 calc(33% - 20px);
    }
    .tab-panel.active{
        gap:40px
    }
}

@media (max-width: 768px) {
    .tab-panel .tarif-card {
        flex: 1 1 100%;
        max-width: 100%;
    }

    .tarif-text{
        min-height: auto;
    }

    .form-content-tariff  h2 {
        font-size: 24px;
        padding-bottom: 20px;
    }
}

/* ==========================================
   Univerzální hero sekce TNtech
   Nezávislá na rodičovském ID.
   ========================================== */

.tn-ultra-hero,
.tn-ultra-hero * {
    box-sizing: border-box;
}

.tn-ultra-hero {
    --tn-ultra-primary: #8302e8;
    --tn-ultra-dark: #1a0b36;
    --tn-ultra-dark-secondary: #2b1055;
    --tn-ultra-text: #ffffff;
    --tn-ultra-muted: #e9e3f3;
    --tn-ultra-accent: #d9b5ff;

    /* Celý řádek v gridu nebo zalamovaném flexu */
    grid-column: 1 / -1;
    flex: 0 0 100%;

    display: block;
    width: 100%;
    max-width: 1200px;
    min-width: 0;
    margin: 32px auto;
    padding: clamp(24px, 4%, 48px);

    border: 1px solid var(--tn-ultra-dark-secondary);
    border-radius: 28px;

    background:
            radial-gradient(
                    ellipse at 100% 0%,
                    rgba(131, 2, 232, 0.55),
                    transparent 65%
            ),
            linear-gradient(
                    125deg,
                    var(--tn-ultra-dark),
                    var(--tn-ultra-dark-secondary)
            );

    color: var(--tn-ultra-text);
    font-family: Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    text-align: left;

    box-shadow: 0 12px 32px rgba(26, 11, 54, 0.12);

    /*
     * Responzivita podle skutečné šířky sekce.
     * Funguje také v úzkém sloupci na velkém monitoru.
     */
    container-name: tn-ultra;
    container-type: inline-size;
}

/* Vnitřní rozložení */
.tn-ultra-hero .tn-ultra-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: center;
    gap: 28px;
    min-width: 0;
}

.tn-ultra-hero .tn-ultra-copy,
.tn-ultra-hero .tn-ultra-offer {
    min-width: 0;
    overflow-wrap: anywhere;
}

/* Horní popisek */
.tn-ultra-hero .tn-ultra-eyebrow {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin: 0 0 18px;

    color: var(--tn-ultra-accent);
    font-size: 12px;
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.tn-ultra-hero .tn-ultra-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;

    background: var(--tn-ultra-primary);
    color: var(--tn-ultra-text);
    font-size: 11px;
}

/* Nadpis a popis */
.tn-ultra-hero .tn-ultra-copy h2 {
    margin: 0 0 18px;
    padding: 0;

    color: var(--tn-ultra-text);
    font-family: inherit;
    font-size: 32px;
    font-weight: 800;
    line-height: 1.12;
    letter-spacing: -0.035em;
    text-transform: none;
}

.tn-ultra-hero .tn-ultra-copy h2 span {
    color: var(--tn-ultra-accent);
}

.tn-ultra-hero .tn-ultra-description {
    margin: 0 0 24px;
    padding: 0;
    color: var(--tn-ultra-muted);
    font-size: 16px;
    line-height: 1.7;
}

/* Výhody */
.tn-ultra-hero .tn-ultra-features {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 20px;
    margin: 0 0 28px;
    padding: 0;
    list-style: none;

    color: var(--tn-ultra-text);
    font-size: 14px;
    line-height: 1.5;
}

.tn-ultra-hero .tn-ultra-features li {
    margin: 0;
    padding: 0;
    list-style: none;
}

.tn-ultra-hero .tn-ultra-features li::before {
    content: "✓";
    margin-right: 8px;
    color: var(--tn-ultra-accent);
}

.tn-ultra-hero .tn-ultra-features strong {
    color: inherit;
    font-weight: 700;
}

/* Tlačítko */
.tn-ultra-hero .tn-ultra-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;

    width: 100%;
    max-width: 100%;
    min-height: 48px;
    margin: 0;
    padding: 14px 22px;

    border: 1px solid #ffffff;
    border-radius: 20px;
    background: #ffffff;
    color: var(--tn-ultra-primary);

    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.5;
    text-align: center;
    text-decoration: none;
    white-space: normal;

    transition:
            background-color 0.2s ease,
            color 0.2s ease;
}

.tn-ultra-hero .tn-ultra-button:hover {
    border-color: #f3e8f9;
    background: #f3e8f9;
    color: #6f00c4;
    text-decoration: none;
}

.tn-ultra-hero .tn-ultra-button:focus-visible {
    outline: 3px solid var(--tn-ultra-accent);
    outline-offset: 5px;
}

.tn-ultra-hero .tn-ultra-button > span {
    flex-shrink: 0;
    color: inherit;
}

/* Panel s nabídkou */
.tn-ultra-hero .tn-ultra-offer {
    padding: 30px 24px;
    border: 1px solid rgba(233, 227, 243, 0.3);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.06);
    text-align: center;
}

.tn-ultra-hero .tn-ultra-name {
    margin: 0 0 18px;
    padding: 0;

    color: var(--tn-ultra-text);
    font-family: inherit;
    font-size: 22px;
    font-weight: 700;
    line-height: 1.3;
    text-transform: none;
}

.tn-ultra-hero .tn-ultra-speed {
    margin: 0;
    padding: 0;
    color: var(--tn-ultra-text);
    font-size: 36px;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -0.04em;
}

.tn-ultra-hero .tn-ultra-speed-caption {
    margin: 8px 0 24px;
    padding: 0;
    color: var(--tn-ultra-accent);
    font-size: 14px;
    line-height: 1.5;
}

.tn-ultra-hero .tn-ultra-price {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding-top: 22px;
    border-top: 1px solid rgba(233, 227, 243, 0.25);

    color: var(--tn-ultra-muted);
    font-size: 14px;
    line-height: 1.5;
}

.tn-ultra-hero .tn-ultra-price strong {
    color: var(--tn-ultra-text);
    font-size: 28px;
    font-weight: 700;
}

.tn-ultra-hero .tn-ultra-note {
    margin: 16px 0 0;
    padding: 0;
    color: var(--tn-ultra-muted);
    font-size: 13px;
    line-height: 1.6;
}

/* Dva sloupce, když má samotná sekce dost místa */
@container tn-ultra (min-width: 700px) {
    .tn-ultra-hero .tn-ultra-inner {
        grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
        gap: 32px;
    }

    .tn-ultra-hero .tn-ultra-copy h2 {
        font-size: clamp(36px, 4.8cqi, 48px);
    }

    .tn-ultra-hero .tn-ultra-speed {
        font-size: clamp(36px, 4.8cqi, 48px);
    }

    .tn-ultra-hero .tn-ultra-button {
        width: auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    .tn-ultra-hero .tn-ultra-button {
        transition: none;
    }
}

/* Příklady využití rychlého internetu */
.tn-ultra-hero .tn-ultra-examples {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    margin: 0 0 16px;
}

.tn-ultra-hero .tn-ultra-example {
    min-width: 0;
    padding: 18px 20px;
    border: 1px solid rgba(233, 227, 243, 0.18);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.05);
}

.tn-ultra-hero .tn-ultra-example-label {
    display: block;
    margin-bottom: 6px;
    color: var(--tn-ultra-accent, #d9b5ff);
    font-size: 11px;
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: 0.08em;
}

.tn-ultra-hero .tn-ultra-example h3 {
    margin: 0 0 6px;
    padding: 0;
    color: #ffffff;
    font-family: inherit;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.35;
    text-transform: none;
}

.tn-ultra-hero .tn-ultra-example p {
    margin: 0;
    padding: 0;
    color: var(--tn-ultra-muted, #e9e3f3);
    font-size: 14px;
    line-height: 1.6;
}

.tn-ultra-hero .tn-ultra-performance-note {
    margin: 0 0 24px;
    padding: 0;
    color: var(--tn-ultra-muted, #e9e3f3);
    font-size: 12px;
    line-height: 1.6;
}

/* ==========================================
   TNtech – kompaktní vyhledávání dostupnosti
   ========================================== */

#search-tariff {
    --tn-search-purple: #9742eb;
    --tn-search-text: #152449;

    width: 100%;
    margin: 40px auto 0;
    padding: 0;
    text-align: left;
}

#search-tariff .tn-address-search,
#search-tariff .tn-address-search * {
    box-sizing: border-box;
}

/* Nadpis */

#search-tariff > label {
    display: block;
    width: 100%;
    max-width: 1080px;
    margin: 0 auto 10px;
    padding: 0;

    color: var(--tn-search-text);
    font-family: inherit;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    text-align: left;
}

/* Společný rámeček */

#search-tariff .tn-address-search {
    display: flex;
    align-items: center;
    gap: 6px;

    width: 100%;
    max-width: 1080px;
    min-height: 58px;
    margin: 0 auto;
    padding: 5px;

    border: 1px solid #e2e7f3;
    border-radius: 999px;
    background: #f5f6fd;
    overflow: visible;
}

/* Oblast vstupu */

#search-tariff #address-input-wrap {
    display: block;
    position: relative;
    flex: 1 1 0;
    width: auto;
    min-width: 0;
    margin: 0;
}

/* Ikona adresy */

#search-tariff #address-input-wrap::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 16px;

    width: 20px;
    height: 20px;

    transform: translateY(-50%);
    pointer-events: none;

    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23576582' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 10c0 6-8 12-8 12S4 16 4 10a8 8 0 1 1 16 0Z'/%3E%3Ccircle cx='12' cy='10' r='3'/%3E%3C/svg%3E")
    center / contain no-repeat;
}

/* Vstupní pole */

#search-tariff #address-input {
    display: block;
    width: 100%;
    max-width: none;
    height: 46px;
    margin: 0;
    padding: 0 40px 0 48px;

    border: 0;
    border-radius: 999px;
    background: transparent;
    box-shadow: none;

    color: var(--tn-search-text);
    font-family: inherit;
    font-size: 16px;
    line-height: normal;
}

#search-tariff #address-input::placeholder {
    color: #576582;
    opacity: 1;
}

#search-tariff #address-input:focus {
    outline: none;
}

#search-tariff .tn-address-search:focus-within {
    border-color: var(--tn-search-purple);
    box-shadow: 0 0 0 3px rgba(151, 66, 235, 0.1);
}

/* Tlačítko */

#search-tariff #check-availability {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;

    min-width: 100px;
    min-height: 46px;
    margin: 0;
    padding: 10px 20px;

    border: 0;
    border-radius: 999px;
    background: var(--tn-search-purple);

    color: #fff;
    font-family: inherit;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;

    transition: background-color 0.2s ease;
}

#search-tariff #check-availability:hover {
    background: #8302e8;
}

#search-tariff #check-availability:focus-visible {
    outline: 3px solid var(--tn-search-text);
    outline-offset: 3px;
}

/* Načítání */

#search-tariff #loading-tariff {
    position: absolute;
    top: 50%;
    right: 12px;

    display: block;
    width: 22px;
    height: 22px;
    margin: 0;

    transform: translateY(-50%);
    pointer-events: none;
}

#search-tariff #loading-tariff.hidden {
    display: none;
}

#search-tariff .loading-spinner {
    width: 22px;
    height: 22px;

    border: 2px solid #ddd2ee;
    border-top-color: var(--tn-search-purple);
    border-radius: 50%;

    animation: tn-address-spin 0.8s linear infinite;
}

@keyframes tn-address-spin {
    to {
        transform: rotate(360deg);
    }
}

/* Našeptávač adres */

#search-tariff #suggestions {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    z-index: 100;

    display: none;
    width: 100%;
    max-height: 280px;
    overflow-y: auto;

    border: 1px solid #e2e7f3;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(21, 36, 73, 0.12);

    text-align: left;
}

#search-tariff .suggestion-item {
    padding: 12px 16px;
    border-bottom: 1px solid #eef0f6;

    color: var(--tn-search-text);
    font-size: 15px;
    line-height: 1.5;
    cursor: pointer;
}

#search-tariff .suggestion-item:last-child {
    border-bottom: 0;
}

#search-tariff .suggestion-item:hover {
    background: #f3eafb;
}

/* Zprávy pod vyhledáváním */

#search-tariff #availability-result {
    margin-top: 20px;
    color: #333;
    font-size: 16px;
    line-height: 1.6;
    text-align: center;
}

#search-tariff #availability-result:empty {
    margin-top: 0;
}


/* Celý blok včetně výsledků */
#search-tariff {
    width: 100%;
    max-width: none;
}

/* Jen nadpis a vyhledávací pole */
#search-tariff > label,
#search-tariff .tn-address-search {
    width: 100%;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Výsledky přes celou dostupnou šířku */
#search-tariff #availability-result,
#search-tariff #tariffs-s-r {
    width: 100%;
    max-width: none;
    box-sizing: border-box;
}

/* Rozložení nalezených tarifů */
#search-tariff #tariffs-s-r {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

/* Mobil */

@media (max-width: 650px) {
    #search-tariff > label {
        font-size: 16px;
    }

    #search-tariff .tn-address-search {
        gap: 4px;
    }

    #search-tariff #address-input-wrap::before {
        left: 8px;
        width: 18px;
        height: 18px;
    }

    #search-tariff #address-input {
        padding: 0 36px 0 32px;
        font-size: 16px;
    }

    #search-tariff #check-availability {
        min-width: 80px;
        padding: 10px 14px;
        font-size: 14px;
    }

    #search-tariff #loading-tariff {
        right: 8px;
    }
}

@media (prefers-reduced-motion: reduce) {
    #search-tariff #check-availability {
        transition: none;
    }

    #search-tariff .loading-spinner {
        animation: none;
    }
}