﻿/* Please see documentation at https://docs.microsoft.com/aspnet/core/client-side/bundling-and-minification
for details on configuring this project to bundle and minify static web assets. */

@font-face {
    font-style: normal;
    font-display: block;
    font-family: 'Iran Yekan Regular';
    src: url('../fonts/IRANSans-Regular.ttf');
}

@font-face {
    font-style: normal;
    font-weight: bold;
    font-display: block;
    font-family: 'Iran Yekan Bold';
    src: url('../fonts/IRANSans-Bold.ttf');
}
/* Colours a client may override through its Theme in the clients file (a <style> block after this
   file sets the ones it defines). Defaults are the look without a Theme: this file's own values,
   and Bootstrap 4.3.1's for the states this file never styled (hover, pressed, focus). */
:root {
    --brand-primary: #1b6ec2;
    --brand-primary-border: #1861ac;
    --brand-primary-hover: #0069d9;
    --brand-primary-hover-border: #0062cc;
    --brand-primary-active: #0062cc;
    --brand-primary-active-border: #005cbf;
    --brand-focus-ring: rgba(38, 143, 255, 0.5);
    --brand-nav-link: #007bff;
    --brand-btn-link: #007bff;
    --brand-link: #0366d6;
    --brand-input-focus-border: #80bdff;
    --brand-input-focus-ring: rgba(0, 123, 255, 0.25);
}

body {
    font-size: 11pt;
}

/* Direction follows the active culture: the layout writes dir="rtl"/"ltr" onto <html>
   from CultureInfo.CurrentUICulture.TextInfo.IsRightToLeft. */
html[dir="rtl"] body {
    font-family: 'Iran Yekan Regular';
    direction: rtl;
    text-align: right;
}

html[dir="ltr"] body {
    direction: ltr;
    text-align: left;
}

.language-switcher .dropdown-menu {
    min-width: 8rem;
}

.language-switcher .dropdown-item {
    background: none;
    border: 0;
    width: 100%;
    text-align: inherit;
    cursor: pointer;
}

/* The language already in use stays readable and is simply muted, rather than taking
   Bootstrap's .active treatment (white text) on the background this menu removes. */
.language-switcher .dropdown-item.active,
.language-switcher .dropdown-item.active:hover,
.language-switcher .dropdown-item.active:focus,
.language-switcher .dropdown-item:disabled {
    color: #6c757d;
    background: none;
    cursor: default;
    opacity: 1;
}
a.navbar-brand {
    white-space: normal;
    text-align: center;
    word-break: break-all;
}
.text-aligner{
    text-align: justify;
}

.nav-link{
    padding:5px;
}

.btn{
    font-size:11pt;
}

.btn-small {
    font-size: 8pt !important;
    height:25px !important;
}

.nav-link-separator {
    padding: 5px;
    color: gray;
}

.navbar-nav-pad-remover{
    padding:0px !important;
}
.nav-pills .nav-link.active {
    color: #fff !important;
    background-color: var(--brand-primary);
    border-color: var(--brand-primary-border);
}

.nav-pills .nav-link {
    color: var(--brand-nav-link); /* Inactive text color */
    font-size: smaller !important;
}

/* Provide sufficient contrast against white background */
a {
    color: var(--brand-link);
}

.btn-primary {
    color: #fff;
    background-color: var(--brand-primary);
    border-color: var(--brand-primary-border);
}

.btn-primary:hover {
    background-color: var(--brand-primary-hover);
    border-color: var(--brand-primary-hover-border);
}

.btn-primary:focus, .btn-primary.focus,
.btn-primary:not(:disabled):not(.disabled):active:focus,
.btn-primary:not(:disabled):not(.disabled).active:focus {
    box-shadow: 0 0 0 0.2rem var(--brand-focus-ring);
}

.btn-primary:not(:disabled):not(.disabled):active,
.btn-primary:not(:disabled):not(.disabled).active {
    background-color: var(--brand-primary-active);
    border-color: var(--brand-primary-active-border);
}

.btn-link {
    color: var(--brand-btn-link);
}

.form-control:focus {
    border-color: var(--brand-input-focus-border);
    box-shadow: 0 0 0 0.2rem var(--brand-input-focus-ring);
}

.nav-pills .nav-link.active, .nav-pills .show > .nav-link {
    color: #fff;
    background-color: var(--brand-primary);
    border-color: var(--brand-primary-border);
}

/* Sticky footer styles
-------------------------------------------------- */

.border-top {
    border-top: 1px solid #e5e5e5;
}

.border-bottom {
    border-bottom: 1px solid #e5e5e5;
}

.box-shadow {
    box-shadow: 0 .25rem .75rem rgba(0, 0, 0, .05);
}

button.accept-policy {
    font-size: 1rem;
    line-height: inherit;
}

/* Sticky footer styles
-------------------------------------------------- */
html {
    position: relative;
    min-height: 100%;
}

body {
    /* Margin bottom by footer height */
    margin-bottom: 60px;
}

.footer {
    position: absolute;
    bottom: 0;
    width: 100%;
    white-space: nowrap;
    line-height: 60px; /* Vertically center the text there */
}

/* Manage/EnableAuthenticator: the QR code qr.js draws (200 by 200), centred in the column
   whichever element qrcode.js shows (the canvas, or the img it makes from it) */
.authenticator-qr {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
}

.authenticator-qr > canvas,
.authenticator-qr > img {
    max-width: 100%;
}

/* Manage/ShowRecoveryCodes: the codes, two to a row, easy to copy */
.recovery-codes {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

/* the manual key under it: grows with its text (form-control's fixed height would let a second
   line spill out), breaks only between its four-letter groups, one click selects all of it.
   Small enough that the eight groups fit one line in the column; on a very narrow screen they wrap. */
.form-control.authenticator-key {
    height: auto;
    padding: 0.5rem 0.5rem;
    font-size: 0.8125rem;
    line-height: 1.6;
    white-space: normal;
    overflow-wrap: normal;
    word-break: keep-all;
    user-select: all;
}

/* from md up the Manage panel is about 460px wide (PR 693): the key grows to fill it, still on one line,
   and the recovery codes match it */
@media (min-width: 768px) {
    .form-control.authenticator-key {
        font-size: 1.1875rem;
        padding: 0.5rem 0.75rem;
    }

    /* ShowRecoveryCodes: the codes the same size as the key */
    .recovery-code {
        font-size: 1.1875rem;
    }
}

/* Manage: the five tabs (Profile, Password, Services, Two-factor, My data) sit on one line once the
   navbar expands; the panel column is wide enough for them in every language */
@media (min-width: 992px) {
    .manage-nav .nav-link {
        white-space: nowrap;
    }
}

/* below lg the tabs stack; the stock navbar drops the link padding there, which glues the text to the
   active pill's edge */
@media (max-width: 991.98px) {
    .manage-nav .nav-link {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }
}
